Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
control-level triggers
#5
Its very hard to attach a toolbar to that particular part of word but this is working for me on microsoft office 2106 word on windows 10

function starts when word window is created and active

Function WordSaveAsToolbarLauncher
Trigger !ca"- Word" "OpusApp"     Help - how to add the trigger to the macro
Code:
Copy      Help
int hwnd=TriggerWindow
;top
rep
,0.2
,Acc a.Find(hwnd "STATICTEXT" "Save As" "class=NetUIHWND" 0x5 0.3)
,err
,,if !IsWindow(hwnd)
,,,ret        
,if(a.Hwnd)
,,err
,,,continue
,,break
,if !IsWindow(hwnd)
,,ret

int cwh= a.Hwnd
int tb=mac("Toolbar1" cwh) ;;edit this(Toolbar1) to match your toolbar name. Opens the toolbar and attaches it to the trigger window of this function.
int visible=1
rep
,if(!IsWindow(tb)) 
,,if(IsWindow(hwnd))
,,,goto top
,,else
,,,ret
,int c=cwh
,if visible!=(c!=0)
,,visible=c!=0
,,if(visible) hid- tb; else hid tb
,0.5


Messages In This Thread
control-level triggers - by cuitino - 09-18-2019, 01:58 AM
RE: control-level triggers - by Gintaras - 09-18-2019, 04:35 AM
RE: control-level triggers - by Gintaras - 09-18-2019, 04:37 AM
RE: control-level triggers - by cuitino - 09-19-2019, 01:26 PM
RE: control-level triggers - by Kevin - 09-20-2019, 07:18 PM
RE: control-level triggers - by cuitino - 09-23-2019, 03:07 AM
RE: control-level triggers - by cuitino - 09-23-2019, 06:58 PM
RE: control-level triggers - by Kevin - 09-23-2019, 08:20 PM
RE: control-level triggers - by cuitino - 09-24-2019, 01:50 PM
RE: control-level triggers - by redbull2k - 09-24-2019, 03:39 PM
RE: control-level triggers - by cuitino - 09-24-2019, 05:32 PM
RE: control-level triggers - by Gintaras - 09-24-2019, 05:45 PM
RE: control-level triggers - by cuitino - 09-24-2019, 06:03 PM
RE: control-level triggers - by Gintaras - 09-24-2019, 06:19 PM
RE: control-level triggers - by cuitino - 09-24-2019, 07:26 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)