Try accessible object trigger.
Example with Notepad:
Macro Macro6
Trigger $a 140 -4 "" "msctls_statusbar32" 1025 "" "Notepad" "- Notepad" 41
How to know the trigger data?
1. Select QM menu Tools -> Output -> Log -> Acc. trigger events. OK.
2. Activate your program and let it change status bar text.
3. Activate QM and uncheck the same menu item (step 1).
4. Look for trigger info in the output pane. It can look like this (or it can be different, but it must contain the status bar text):
5. In the Properties dialog select trigger "Accessible object". Then enter the trigger info. If using the above info: select EVENT_OBJECT_ -> NAMECHANGE, then in the idObject combobox select CLIENT, in ow class field paste ow class (msctls_statusbar32), in pw fields paste pw class and name, click button Next, select role STATICTEXT.
6. OK. If asks, let it insert trigger data; then uncomment the 2 green lines.
7. Test the trigger: Activate your program and let it change status bar text. If the trigger works, your macro runs and displays status bar text in QM output.
Example with Notepad:
Macro Macro6
Trigger $a 140 -4 "" "msctls_statusbar32" 1025 "" "Notepad" "- Notepad" 41
;\
function hwnd idObject idChild
Acc a.FromEvent(hwnd idObject idChild)
str s=a.Name
out s
sel s 1|2
,case "*error*"
,out "ERROR"
How to know the trigger data?
1. Select QM menu Tools -> Output -> Log -> Acc. trigger events. OK.
2. Activate your program and let it change status bar text.
3. Activate QM and uncheck the same menu item (step 1).
4. Look for trigger info in the output pane. It can look like this (or it can be different, but it must contain the status bar text):
8. NAMECHANGE, CLIENT, 2
ow: class="msctls_statusbar32", id=1025
pw: class="Notepad", name="Untitled - Notepad"
ao: role=STATICTEXT, state=0x0, name=" Ln 1, Col 2 "
6. OK. If asks, let it insert trigger data; then uncomment the 2 green lines.
7. Test the trigger: Activate your program and let it change status bar text. If the trigger works, your macro runs and displays status bar text in QM output.