Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Specific Tab in Firefox browser for Trigger
i am trying to use a window Trigger for a group of macros.

the window is a Firefox browser, BUT it is specific for a webpage/domain and the Tab text doesnt make reference to the domanin or page.   If I use the "Window Name" it does not have a specific reference that I can use. using class = Mozilla is to general.  i see a Control input in the windows trigger, but dont think it would appy (please adivse)

i have identified a Logo on the page which is a HREF which only appears on the pages with in this website. I can locate it using the Accessible Object Access functionality, but now, how can I use this information as a trigger so my macro only runs on this website pages with this logo, text?

Macro Macro2
Copy      Help
int w1=wait(3 WV win(" - Mozilla Firefox" "MozillaWindowClass"))
Acc a.Find(w1 "LINK" "datacamp-logo" "value=[]a:href=" 0x3015 3)
This macro runs when Firefox window name changes, and prints "TRIGGERED" when the web page contains certain link that is in QM forum pages.

Macro Macro300
Trigger !n"- Mozilla Firefox" "MozillaWindowClass"     Help - how to add the trigger to the macro
Copy      Help
int hwnd=TriggerWindow
str name.getwintext(hwnd)
out name ;;remove this
sel name
,case "New Tab - Mozilla Firefox"

Acc a.Find(hwnd "LINK" "Quick Macros Forum" "" 0x2011)
if(a.NotFound) ret


so technically no trigger is assign to this macro?  or do i set the trigger as window with Mozilla as name which will run this code and check IF the page contains correct text/link..? not 100% sure how this would work....

also... is this a 1x thing, meaning if i switch tab and come back to the tab with link, it wont reactivate the trigger/macro, i would have to move off window then return to window to "re-trigger"?

just a quick explantion if you can.. thank you
The trigger is above code in my post.

Not 1x.
You can set the trigger to whatever you want. Setting it to an active trigger will only activate and do whatever IF such object is visible

Forum Jump:

Users browsing this thread: 1 Guest(s)