Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[solved] find text and get position of found text
#1
Hi,

My macro needs to:

1. ctrl-f to find some keyword in firefox
2. once the keyword is found, I need to get the xy coordinates of the found text

Thanks for reading.
#2
Get coordinates of selected text? This is probably possible in Internet Explorer, but not in Firefox. QM cannot access full Firefox DOM like Javascript in Firefox.
#3
When I press escape after finding the text, I can press the context menu (the button beside the windows button) and the context menu pops up where the text is, so could I find the caret's xy that way?
#4
Macro Macro2217
Code:
Copy      Help
int w=wait(10 WV win("" "MozillaDropShadowWindowClass")) ;;wait for a Firefox menu window
int x y
GetWinXY w x y
mou x y
#5
Thanks. I modified it slightly and it gave the up-left corner x y for the context menu, but it is unreliable because its position shifts when the cursor is at the bottom of the screen. i'm reading your other code for accessible objects - sounds very promising!


Forum Jump:


Users browsing this thread: 1 Guest(s)