Noe Posted February 9, 2006 Share Posted February 9, 2006 I am coding a script to automate an operation for application. During the operation, I will select a item from a .net combobox control. The the code likes below. But seems not work. ControlCommand("WinTitle","WinText","WindowsForms10.COMBOBOX.app31","SelectString", "LA") There should be no problem for the recognization of the control as when I used the command parameter "ShowDropDown". The dropdown list is shown. Can anyone help me figure out what's wrong here? Or is there any other solutions? As that combobox is not created by GuiCtrlCreate, I think I can not use any function in GuiCombobox.au3, right? Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted February 9, 2006 Moderators Share Posted February 9, 2006 I am coding a script to automate an operation for application. During the operation, I will select a item from a .net combobox control. The the code likes below. But seems not work. ControlCommand("WinTitle","WinText","WindowsForms10.COMBOBOX.app31","SelectString", "LA")There should be no problem for the recognization of the control as when I used the command parameter "ShowDropDown". The dropdown list is shown. Can anyone help me figure out what's wrong here? Or is there any other solutions?As that combobox is not created by GuiCtrlCreate, I think I can not use any function in GuiCombobox.au3, right?Sorry, the crystal ball is broken today... Got your script anywhere? ... Would you like to post it so we can see what the issue is? Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
BigDod Posted February 9, 2006 Share Posted February 9, 2006 Sorry, the crystal ball is broken today... Got your script anywhere? ... Would you like to post it so we can see what the issue is?You must spend a fortune on crystal balls the amount of them you break Time you enjoyed wasting is not wasted time ......T.S. Elliot Suspense is worse than disappointment................Robert Burns God help the man who won't help himself, because no-one else will...........My Grandmother Link to comment Share on other sites More sharing options...
Noe Posted February 10, 2006 Author Share Posted February 10, 2006 Sorry, the crystal ball is broken today... Got your script anywhere? ... Would you like to post it so we can see what the issue is?Below is the code. The attached snapshot is the window I want to operate. ;====================#include <File.au3>Dim $appDir="I:\Program Files\DriveCam\HindSight Admin Tools\"Dim $expWin; ====================================================; Launch admin toolsRun($appDir & "adminTool.exe"); ====================================================; LoginWinWaitActive("Login - Admin Tools","Version")ControlSetText("Login - Admin Tools","Version","WindowsForms10.EDIT.app31","aaa")ControlSetText("Login - Admin Tools","Version","WindowsForms10.EDIT.app32","aaa")ControlClick("Login - Admin Tools","Version","WindowsForms10.BUTTON.app31"); ====================================================; Launch Registration DialogControlClick("Admin Tools","","WindowsForms10.window.8.app32"); ====================================================; RegisterControlSetText("HindSight Registration","Company Information","WindowsForms10.EDIT.app35","sdfasdfasfddfads@3424234453")ControlSetText("HindSight Registration","Company Information","WindowsForms10.EDIT.app34","sdfdasrersjguytuasdfasfddfads@3424234453")ControlSetText("HindSight Registration","Company Information","WindowsForms10.EDIT.app31","sdfasdfasfddfadsvdtyt@3424234453")ControlSetText("HindSight Registration","Company Information","WindowsForms10.EDIT.app33","Noe's City")ControlCommand("HindSight Registration","Company Information","WindowsForms10.COMBOBOX.app31","SelectString", "LA") Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted February 10, 2006 Moderators Share Posted February 10, 2006 You might want to take a look at 'ControlCommand', and ShowDropDown. Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer. Link to comment Share on other sites More sharing options...
Noe Posted February 10, 2006 Author Share Posted February 10, 2006 You might want to take a look at 'ControlCommand', and ShowDropDown.I tried the code below:ControlCommand("HindSight Registration","Company Information","WindowsForms10.COMBOBOX.app31","ShowDropDown", "")But it only dropdown the list of that combobox, not select an item. Link to comment Share on other sites More sharing options...
Noe Posted February 11, 2006 Author Share Posted February 11, 2006 The code below does not work either. ControlCommand("HindSight Registration","Company Information","WindowsForms10.COMBOBOX.app31","ShowDropDown", "LA"). Is there any other ways? Link to comment Share on other sites More sharing options...
=sinister= Posted February 11, 2006 Share Posted February 11, 2006 Im taking a HUGE guess : ControlCommand("HindSight Registration","","WindowsForms10.COMBOBOX.app31","ShowDropDown", "LA"). If it doesn't work, im not suprised. Link to comment Share on other sites More sharing options...
Noe Posted February 11, 2006 Author Share Posted February 11, 2006 Im taking a HUGE guess : ControlCommand("HindSight Registration","","WindowsForms10.COMBOBOX.app31","ShowDropDown", "LA"). If it doesn't work, im not suprised. Then How to use controlcommand to select an item in combobox? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now