BSAT Posted January 12, 2018 Posted January 12, 2018 Hi, I am trying to automate certain steps of a thin client C# desktop application. I am able to open the application using ShellExecute command but unable to do any actions on it. When trying to right click or display a message box, both actions are being performed after I close the desktop application. Instead, both actions should be performed on the desktop application window. I believe the desktop app window is not the active window. Any idea how to resolve this issue and make the desktop application window as Active window. Any inputs appreciated. Thanks. BSAT
Earthshine Posted January 12, 2018 Posted January 12, 2018 what code have you tried? can you post it to see if others here can assist? right off the bat I am thinking you need to use IUIAutomation UDF as the client app is C# My resources are limited. You must ask the right questions
Moderators JLogan3o13 Posted January 12, 2018 Moderators Posted January 12, 2018 @BSAT welcome to the forum. You will find that it makes it extremely difficult to offer suggestions on improving your code without actually seeing that code. It sounds as though you might be using ShellExecuteWait, or have some other blocking function in there, but unfortunately you're leaving us to guess. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
BSAT Posted January 12, 2018 Author Posted January 12, 2018 Thank you for your reply. Here are the details: Code used in the script: ;to open the desktop application ShellExecuteWait("C:\**\**\***.exe") ;displaying the message box for testing purpose MsgBox(0, "test", "testing") ;right clicking the mouse for testing purpose MouseClick("right", 125, 313) When executing this code, after the application opens no message box or right click happens on the application window. Instead, when I close the application; that's when message box is displayed and right click of the mouse Can I get the details of the active window? Or How can I make the application window active so that the actions are performed on the application window? I need to click on specific controls on the application. I cant click since the application window is not active.
Earthshine Posted January 12, 2018 Posted January 12, 2018 AU3Info from tools menu of the editor My resources are limited. You must ask the right questions
BSAT Posted January 12, 2018 Author Posted January 12, 2018 Thank you, you mean Tools menu of the SciTE Script Editor? I don't have that option.
Earthshine Posted January 12, 2018 Posted January 12, 2018 (edited) You need to install the full editor Listed on the downloads page. Also you’ll want to latest version of auto IT Edited January 12, 2018 by Earthshine My resources are limited. You must ask the right questions
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