Find Text on a button in applications

Hints, tips and tricks for newbies

Moderators: Dorian (MJT support), JRL

Post Reply
jon
Newbie
Posts: 8
Joined: Fri Oct 21, 2005 4:45 am

Find Text on a button in applications

Post by jon » Mon Oct 24, 2005 12:43 pm

Hello,

Very newbie here, so excuse the ignorance...

I'm trying figure out if there's a way to find text on an applications and execute the commands from msched pro.

What I'm trying to do is run a sequence of commands that will accomplish, lets say, encode a video to WMV. I know I can use the msched "Recorder" and just record my mouse, keyboard movements, but I want to make it more efficient by executing commands in the script editor.

Example:

1) Open the program; set focus to the app. (I know how to do this now)
2) Select what type of video I want to encode from a list on the video encoder application.
3) then find the button in the application that says encode more video, and repeat the steps.

Again, I'm a noob...

Thanks for the help guys.

Jon

User avatar
pgriffin
Automation Wizard
Posts: 460
Joined: Wed Apr 06, 2005 5:56 pm
Location: US and Europe

Post by pgriffin » Mon Oct 24, 2005 2:38 pm

Check out the help files for the GetControlText command.

like this:

GetControlText>MyApp,Button,2,ButtonText

This example looks at a window called MyApp, then looks for the second instance of a Windows object of type 'button', then places the text from the button into ButtonText. You'll need to use View System Windows to locate the controls on the MyApp screen (in this example). Then you'll need to be sure that the app is actually using a windows object like Button (it could be some other type, just use what is used by the app). Then fill in the example with the detail you find in View System Windows.

SkunkWorks.

Post Reply
cron
Sign up to our newsletter for free automation tips, tricks & discounts