GetTextInRect Inconsistencies
Moderators: Dorian (MJT support), JRL
GetTextInRect Inconsistencies
Anyone else having inconsistent results with GetTextInRect? I've ran the function a few times on the exact same block of text and sometimes get a blank and sometimes get the text. Messing with the coordinates a bit makes the results -more- consistent but not totally consistent. If I run it 10 times it'll probably work 8 or 9. Is there something I could be doing wrong?
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Which version of Macro Scheduler are you using? The text capture functions are more reliable in v11 which uses a later version of the text capture libraries.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
Version 11
Using version 11 as of this morning and I'm getting these results.
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
There are some valid reasons why it will sometimes come back blank. The app may be busy/unresponsive when the function is called. I always recommend calling GetTextInRect in a loop. Loop until text returned. You'll notice that the text capture sample uses a loop.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?