Ich habe Winspy verwendet, um eine ahk_class für mein Autohotkey-Makro zu greifen. Manchmal hat, dass die Anwendung 2+ ahk_classes dem Programm zugeordnetAutohotkey: Wildcard ahk_class Übereinstimmung
Beispiel:
HwndWrapper[program.exe;;1111-1111]
HwndWrapper[program.exe;;2222-2222]
Wie kann ich winNotExist verwenden, um einfach nur beide Namen überein? Oder vielleicht ein ||
, OR
etc?
z.
F12::
IfWinNotExist, ahk_class "HwndWrapper.+"
Run, AQ8.exe
GroupAdd, kjexplorers11, ahk_class "HwndWrapper.+" ;You have to make a new group for each application, don't use the same one for all of them!
if WinActive("ahk_exe AQ8.exe")
GroupActivate, kjexplorers11, r
else
WinActivate ahk_class ahk_class "HwndWrapper.+" ;you have to use WinActivatebottom if you didn't create a window group.
Return
Versuchen [SetTitleMatchMode RegEx] (https://autohotkey.com/docs/commands/SetTitleMatchMode.htm) oder eine Gruppe von diesen beiden ahk_classes erstellen mit [GroupAdd] (https: //autohotkey.com/docs/commands/GroupAdd.htm) und 'IfWinNotExist, ahk_group my Group'. – user3419297
Ich verstehe nicht, wie settitlematchmode funktioniert. Die Dokumentation fehlt in guten Beispielen. Woher weiß es, es auf meine ahk_class-Aussagen anzuwenden, die hier zu sehen sind? – Kagerjay