kra55 Posted April 27, 2009 Posted April 27, 2009 (edited) Hey all have been playing around with Tabs now So far i can tabright and left and also retrive the current tab as a number/instance.....I have looked around and cannot see how retrive the name of the selected tab rather then the number. If this is possible please advise...Thanking you in advance Below is what i am using atm but as the tabs change i really need this to be based on name.... $test = ControlCommand("Chicken", "", "[CLASS:SysTabControl32; INSTANCE:2]", "CurrentTab", "") Edited April 27, 2009 by kra55
exodius Posted April 27, 2009 Posted April 27, 2009 Just to clarify, you want the text on the tab? And also, I take it this is in a secondhand-window (as in not an autoit gui that you're making?)?
kra55 Posted April 27, 2009 Author Posted April 27, 2009 Sorry that is correct the text/heading off the tab itself And once again you are correct this is a separate window/ not a user created Autoit gui Im not sure if this makes a difference but when I use the info tool it does show the headings under the visible text.. Thank you
kra55 Posted April 27, 2009 Author Posted April 27, 2009 As no replies guessing this may not be possible - Im guessing the alternative will be for valadate what tab i am on by what is displayed in the tab......Assuming they are all differant which they are.....
kra55 Posted April 27, 2009 Author Posted April 27, 2009 Ok so what i have done below basically searchs the tabs for a particular label once this is found it stops..... Im guessing i could prob make this more efficiant but im happy to just have somthing Now i am dealing with SysListControl....omfg what a pain..... ;go to first tab While ControlCommand("chicken", "", "[CLASS:SysTabControl32; INSTANCE:2]", "CurrentTab", "") <> 1 ControlCommand("chicken", "", "[CLASS:SysTabControl32; INSTANCE:2]", "TabLeft", "") Sleep(50) WEnd ; Search Tabs forcontacts to show we are on the contacts tab While ControlGetText("chicken", "", "Static19") <> "contacts:" ControlCommand("chicken", "", "[CLASS:SysTabControl32; INSTANCE:2]", "TabRight", "") Sleep(50) WEnd
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