Soundarya Posted March 31, 2023 Posted March 31, 2023 I have an AutoIT script and is working fine in my machine. I have compiled it to a standalone exe file and is running fine in my machine. I tried to run from another desktop where the script started and opened the required desktop application, but no other actions performed. I hope it is failing to control the application . Is there a possibility the class name of the application changes from one system to other ? Please suggest how to handle the class names (Example - CLASS:WindowsForms10.Window.8.app.0.bb8560_r18_ad1) in case it will change from one system to other.
Solution mistersquirrle Posted March 31, 2023 Solution Posted March 31, 2023 It would be best if you could take at least the AutoIt Window Info tool onto the other system and check the class name, as that does seem like it could have some version information in it. However the best option would be to add some logging to a file into your script to run on the computer, or just run and debug the script on the other computer manually. You can also use RegEx in the class: https://www.autoitscript.com/autoit3/docs/intro/windowsadvanced.htm For example: WinGetTitle('[REGEXPCLASS:WindowsForms\d+\.Window\.\d+\.app\.\d+\..*?') This should get you started, however this (if it does match anything) may not match the correct window, since it's now a very vague match for any window with a similar class. I suggest that you figure out where the problem is on the other computer first, then ask a more specific question. We ought not to misbehave, but we should look as though we could.
Soundarya Posted April 1, 2023 Author Posted April 1, 2023 @mistersqurrle I found the problem. The class name is CLASS:WindowsForms10.Window.8.app.0.bb8560_r18_ad1 in my system and in other system it is CLASS:WindowsForms10.Window.8.app.0.bb8560_r12_ad1. Can any one help how can I fix the script to work common in all mahcines
Soundarya Posted April 1, 2023 Author Posted April 1, 2023 @mistersquirrle Thanks , your suggestion solved my issue. Thanks for helping to fix this.
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