Pentium Posted September 26, 2006 Share Posted September 26, 2006 Hello friends. I am new to AutoIt and love it at the first sight. I have a question that need your help. I start to write simple scripts to automate some software installations for my group now. One of the installation step provides a two check boxes which I want to uncheck one and check the other before sending the Next [send("!n")]. Windows title is "Remedy User" The box that has checked mark named: Crystal Report The box has no checked mark named: ODBC There is no underscore text for those 2 items to send the !charcters. I need to reverse those two boxes, i.e. uncheck the Crystal Report and check the ODBC. Below that is the Next icon to go for next phase. I don't know how to make it happen. Please help. Regards, Pentium. Link to comment Share on other sites More sharing options...
ChrisL Posted September 26, 2006 Share Posted September 26, 2006 Look up "ControlCommand()" in the help file. The Auto IT window info tool in "Start/programs/Autoit 3" will also be useful for this to identify the control id's [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire Link to comment Share on other sites More sharing options...
Pentium Posted September 26, 2006 Author Share Posted September 26, 2006 Look up "ControlCommand()" in the help file. The Auto IT window info tool in "Start/programs/Autoit 3" will also be useful for this to identify the control id's Hi, I use AutoIt Widows Info as you've said. It's great help to inquire the info. I found this control: ControlCommand ("Title", "text", controlID, "command" ["option"]) as ControlCommand ("Remedy", "Select Components", 401, "uncheck") But the box I want to uncheck is at the left of "Crystal Reports", and the box and want to check is left of "ODBC". Can someone help me how to let the ControlCommand selects the boxes next to those 2 texts, and perform check or uncheck command on them? Cheers, P. Link to comment Share on other sites More sharing options...
ChrisL Posted September 26, 2006 Share Posted September 26, 2006 Hi, I use AutoIt Widows Info as you've said. It's great help to inquire the info. I found this control: ControlCommand ("Title", "text", controlID, "command" ["option"]) as ControlCommand ("Remedy", "Select Components", 401, "uncheck") But the box I want to uncheck is at the left of "Crystal Reports", and the box and want to check is left of "ODBC". Can someone help me how to let the ControlCommand selects the boxes next to those 2 texts, and perform check or uncheck command on them? Cheers, P. If you hover over the two check boxes do they have a separate control ID [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire Link to comment Share on other sites More sharing options...
Pentium Posted September 26, 2006 Author Share Posted September 26, 2006 If you hover over the two check boxes do they have a separate control IDNo, they don't have separate ControlID. When I ran the Windows Info and put the cursor over it I got the a big box that contains those two check boxes. The info shows below.CotrolID: 401ClassNameNN: ISAVIEWCMPTCLASS1Text: ISAVIEWCMPTWINDOWStyle: 0x50010000ExStyle: 0x0000000Thanks,P. Link to comment Share on other sites More sharing options...
ChrisL Posted September 26, 2006 Share Posted September 26, 2006 No, they don't have separate ControlID. When I ran the Windows Info and put the cursor over it I got the a big box that contains those two check boxes. The info shows below.CotrolID: 401ClassNameNN: ISAVIEWCMPTCLASS1Text: ISAVIEWCMPTWINDOWStyle: 0x50010000ExStyle: 0x0000000Thanks,P.If this is the case then I guess your best bet is to use mouse co-ordinates.Using the info tool work out the co-ordinates of the 2 check boxes, and then probably using pixel checksum on the tick box(s) you could work out if it had a tick in it, you could then click the co-ordinates of the tick box and vice versa on the one you want to uncheck [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire Link to comment Share on other sites More sharing options...
Pentium Posted September 26, 2006 Author Share Posted September 26, 2006 If this is the case then I guess your best bet is to use mouse co-ordinates.Using the info tool work out the co-ordinates of the 2 check boxes, and then probably using pixel checksum on the tick box(s) you could work out if it had a tick in it, you could then click the co-ordinates of the tick box and vice versa on the one you want to uncheckI figure I can do it that way but since each computer in the group might have different Desktop settings (size), so program it to click on certain coordinates might produce wrong input. Do you think so? I hope there are some other function, control to change it. CHeers,P. Link to comment Share on other sites More sharing options...
ChrisL Posted September 27, 2006 Share Posted September 27, 2006 I figure I can do it that way but since each computer in the group might have different Desktop settings (size), so program it to click on certain coordinates might produce wrong input. Do you think so? I hope there are some other function, control to change it. CHeers,P.Have a look at AutoItSetOption()You can tell autoit to use co-ordinates relative to the screen or the active window.Also you could winmove() the window to a specific area and size and also you may want to WinSetOnTop() too [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire Link to comment Share on other sites More sharing options...
Pentium Posted September 27, 2006 Author Share Posted September 27, 2006 Have a look at AutoItSetOption()You can tell autoit to use co-ordinates relative to the screen or the active window.Also you could winmove() the window to a specific area and size and also you may want to WinSetOnTop() tooBeing a newbee to AutoIt it might be a bit of reading, and trials and errors. I would read more on this but have no time now due to heavy work load. I would appreciate very much if you just show me the code line to do that in term of relative coordinates. I will try to learn more this weekend.Cheers,P. Link to comment Share on other sites More sharing options...
ChrisL Posted September 27, 2006 Share Posted September 27, 2006 Seeing as your new around here... AutoitSetOption("MouseCoordMode",0) However a little word of advise, most people on this forum only help those who help themselves or at least put the effort in, most will insist you show what you have already tried. Remember this and you'll go far around here [u]Scripts[/u]Minimize gui to systray _ Fail safe source recoveryMsgbox UDF _ _procwatch() Stop your app from being closedLicensed/Trial software system _ Buffering Hotkeys_SQL.au3 ADODB.Connection _ Search 2d Arrays_SplashTextWithGraphicOn() _ Adjust Screen GammaTransparent Controls _ Eventlogs without the crap_GuiCtrlCreateFlash() _ Simple Interscript communication[u]Websites[/u]Curious Campers VW Hightops Lambert Plant Hire Link to comment Share on other sites More sharing options...
Confuzzled Posted September 28, 2006 Share Posted September 28, 2006 (edited) You could always use a combination of {SEND}ing the {TAB} key and the {space} bar to navigate around the screen and change the setting of the check boxes, couldn't you? Save mucking around with mouse movements... Edited September 28, 2006 by Confuzzled Link to comment Share on other sites More sharing options...
Pentium Posted September 30, 2006 Author Share Posted September 30, 2006 You could always use a combination of {SEND}ing the {TAB} key and the {space} bar to navigate around the screen and change the setting of the check boxes, couldn't you? Save mucking around with mouse movements...Thank you. I'll read more on this and see whether I can send Tab and Space to do it.P. 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