lizardly Posted June 26, 2007 Share Posted June 26, 2007 I have noticed that sometimes my AutoIT .exe will work and sometimes it won't and this is because I'm using CLASS: and INSTANCE: to control focus and events. Sometimes the class shows up as ControlFocus("Encode","","[CLASS:WindowsForms10.EDIT.app.0.3ce0bb8; INSTANCE:3]") and sometimes as ControlFocus("Encode","","[CLASS:WindowsForms10.EDIT.app.0.5c39d4; INSTANCE:3]") The app.0.xxxxxx is changing between the two values. I don't want to code for both. Does anyone see where I'm getting crossed up here? Link to comment Share on other sites More sharing options...
PsaltyDS Posted June 27, 2007 Share Posted June 27, 2007 I have noticed that sometimes my AutoIT .exe will work and sometimes it won't and this is because I'm using CLASS: and INSTANCE: to control focus and events. Sometimes the class shows up as ControlFocus("Encode","","[CLASS:WindowsForms10.EDIT.app.0.3ce0bb8; INSTANCE:3]") and sometimes as ControlFocus("Encode","","[CLASS:WindowsForms10.EDIT.app.0.5c39d4; INSTANCE:3]")Shows up where? What you are listing is code from your own script, not information from the target window. Is that just your way of telling us what you see in Au3Info.exe, or are you controlling your own GUI this way? If it's your GUI, why on earth are you not keeping the control ID when it's created and using that? The app.0.xxxxxx is changing between the two values.When does it change? While running a single instance of the program, after using a certain function, or the next time you run it, or when run on a different computer, each time you compile it, ...? I don't want to code for both.Looks like you already did... Does anyone see where I'm getting crossed up here?Not yet, explain which times are "sometimes". Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
/dev/null Posted June 27, 2007 Share Posted June 27, 2007 The app.0.xxxxxx is changing between the two values.I don't want to code for both.Does anyone see where I'm getting crossed up here?That's because the app is written with/for .Net. Read this for a possible solution: http://www.autoitscript.com/forum/index.php?showtopic=14323 __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
Moderators SmOke_N Posted June 27, 2007 Moderators Share Posted June 27, 2007 That's because the app is written with/for .Net. Read this for a possible solution: http://www.autoitscript.com/forum/index.php?showtopic=14323Orhttp://www.autoitscript.com/forum/index.php?showtopic=30717 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...
lizardly Posted June 27, 2007 Author Share Posted June 27, 2007 Orhttp://www.autoitscript.com/forum/index.php?showtopic=30717Thanks for the input!I should have mentioned it's a .net app so these comments make sense. The fact that there are only 2 values showing upmakes me think that perhaps they depend on which "duel processor" they are being launched on. The ID is guaranteed to change every time the app is launched.I'll look into using the position approach.Thanks! 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