Code: Select all
#NoEnv ;
#singleinstance ignore ;
DetectHiddenWindows, On ;
SetTitleMatchMode, 2 ;
MouseMove, -1600, 1500 ;
Sleep, 1500 ;
Click
MouseMove, 655, 880 ;
Click
Code: Select all
#NoEnv ;
#singleinstance ignore ;
DetectHiddenWindows, On ;
SetTitleMatchMode, 2 ;
MouseMove, -1600, 1500 ;
Sleep, 1500 ;
Click
MouseMove, 655, 880 ;
Click
Code: Select all
If !WinExist("ahk_exe xnviewmp.exe") ; XnView MP
Return
WinActivate
SetKeyDelay, 40
Loop {
WinGetActiveTitle, wTitle
If !(browser := Instr(wTitle, ":\"))
Send ^{Tab}
} Until browser
Send ^{Tab 3}
WinGetActiveTitle, wTitle
Send % Instr(wTitle, ":\") ? "" : "^w"
mikeyww wrote: ↑12 Apr 2021, 08:05Code: Select all
If !WinExist("ahk_exe xnviewmp.exe") ; XnView MP Return WinActivate SetKeyDelay, 40 Loop { WinGetActiveTitle, wTitle If !(browser := Instr(wTitle, ":\")) Send ^{Tab} } Until browser Send ^{Tab 3} WinGetActiveTitle, wTitle Send % Instr(wTitle, ":\") ? "" : "^w"
Ah I missed that. I have XnView set to open separate windows, so I'll play around with it bit later. Thanks!mikeyww wrote: ↑12 Apr 2021, 13:58These are tabs rather than separate program windows. You may need to adjust to fit your situation. The idea is that it navigates through tabs until it finds the XnView browser tab. It then navigates to the next tab three times, and closes that tab. If your XnView does not have a browser tab, or if its window title differs, you may need to adjust. If you run Window Spy, it will show you the window's complete title.
Users browsing this forum: gongnl, hedehede81, ThePeter and 244 guests