Autohotkey 如何检测UWP应用程序正在运行?
这是我最好的猜测,但似乎不起作用。我需要一个解决方案,该解决方案不会在另一个名称中也包含OneNote的窗口上触发,但找不到该窗口。如果该可执行文件名正确且标题MatchMode正确,则代码应该可以工作。如果仍然没有,那么脚本的其他部分肯定还有另一个问题 以下是我如何不仅检测UWP窗口,而且检测所有更难检测的窗口:Autohotkey 如何检测UWP应用程序正在运行?,autohotkey,Autohotkey,这是我最好的猜测,但似乎不起作用。我需要一个解决方案,该解决方案不会在另一个名称中也包含OneNote的窗口上触发,但找不到该窗口。如果该可执行文件名正确且标题MatchMode正确,则代码应该可以工作。如果仍然没有,那么脚本的其他部分肯定还有另一个问题 以下是我如何不仅检测UWP窗口,而且检测所有更难检测的窗口: WinWait ahk_exe onenoteim.exe ; This is my fave TitleMatchMode since it's the most selecti
WinWait ahk_exe onenoteim.exe
; This is my fave TitleMatchMode since it's the most selective
; and gives you the highest level of flexibility.
SetTitleMatchMode RegEx
...
If WinActive("ahk_class ^#32770$ ahk_exe i)\\JPEGView\.exe$")
...
; Here, I chose not to use "ahk_class ^QWidget$" as it occurs a bit too often.
hwnd := WinExist( "GoldenDict$ ahk_exe i)\\GoldenDict\.exe$")
...
Global GC_WINTITLE := " - Google Chrome$ ahk_class ^Chrome_WidgetWin_1$"
WinWait % "New Tab" GC_WINTITLE