Akshay07 Posted January 15, 2010 Share Posted January 15, 2010 Hi all, Au3Info gave me the following information >>>> Window <<<< Title: MyWindow Class: TdlgWatch Handle: 0x000306EA >>>> Control <<<< Class: TButton Instance: 4 ClassnameNN: TButton4 Advanced (Class): [CLASS:TButton; INSTANCE:4] ID: 198608 Text: &Start Handle: 0x000307D0 How can I click this button using these information (if possible, but not required, without activating the corresponding window)? Link to comment Share on other sites More sharing options...
Developers Jos Posted January 15, 2010 Developers Share Posted January 15, 2010 Hi all, Au3Info gave me the following information >>>> Window <<<< Title: MyWindow Class: TdlgWatch Handle: 0x000306EA >>>> Control <<<< Class: TButton Instance: 4 ClassnameNN: TButton4 Advanced (Class): [CLASS:TButton; INSTANCE:4] ID: 198608 Text: &Start Handle: 0x000307D0 How can I click this button using these information (if possible, but not required, without activating the corresponding window)? Open the Helpfile and look at: ControlClick() SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Akshay07 Posted January 15, 2010 Author Share Posted January 15, 2010 Thanks Jos! I am always happy to look into the help file but it is so rich that I don't always know where to start, that was why I asked for some help. So a hint like this one is very welcome (and looking at the help file when working on a specific item leads often to find out much more interesting stuff). Thanks again for the quick answer. Link to comment Share on other sites More sharing options...
Developers Jos Posted January 15, 2010 Developers Share Posted January 15, 2010 Thanks Jos!I am always happy to look into the help file but it is so rich that I don't always know where to start, that was why I asked for some help. So a hint like this one is very welcome (and looking at the help file when working on a specific item leads often to find out much more interesting stuff).Thanks again for the quick answer.It meant it the way I wrote it, but you seems to be reading more into it? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Akshay07 Posted January 15, 2010 Author Share Posted January 15, 2010 (edited) Not at all, in general, I think it is much better for my own learning to be sent back to the help (with some hint on what to look at) instead of being given a "ready to be used" piece of code (well, it depends of the question. sometimes I do need a "ready to be used" piece of code ) I can't find a way to read the controlID when the window is created. It's changing every time. I tested the piece of script when the controlID is known, and it works fine (although it does not work if the window is not activated) WinActivate ( "MyWIndow") ControlClick ( "", "", "[ID:722338]") And ControlClick ( "[CLASS:TButton; INSTANCE:4]", "", "") Does not work Edit ControlClick ( "", "&Start", "") works fine :) Edited January 15, 2010 by Akshay07 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