TextCapture Wizard

Technical support and scripting issues

Moderators: Dorian (MJT support), JRL

Post Reply
jsly845
Newbie
Posts: 1
Joined: Tue Sep 25, 2018 4:00 am

TextCapture Wizard

Post by jsly845 » Tue Sep 25, 2018 4:18 am

Hello,

How would I go about using the TextCapture Wizard to capture some on screen text and then create an If statement if the text is there? Something if the script sees the word Cat on screen it would then move the mouse and LClick.

Thank you,
JS

User avatar
Marcus Tettmar
Site Admin
Posts: 7378
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Re: TextCapture Wizard

Post by Marcus Tettmar » Thu Sep 27, 2018 3:57 pm

The wizard will produce code something like this:

GetTextAtPoint>10,10,theText,ch

So then you could see if the text "Cat" is in the returned string:

Code: Select all

Pos>Cat,theText,1,pPos
If>pPos>0
  //move the mouse and click
  Do something ...
Endif
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

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