AutoHotKey:#IfWinActive。* Explorer *。 ?在Windows 7中

问题描述:

我试图做一个AutoHotkey的宏,在Windows资源管理器仅是积极的,但我不知道浏览器的Windows 7中的名字,我试过如下:AutoHotKey:#IfWinActive。* Explorer *。 ?在Windows 7中

;Make explorer understand that Ctrl+L means goto location bar (like Firefox/Chrome) 
#IfWinActive .* Explorer *. 
    ^l::Send {F4} 
#IfWinActive 

任何想法?

+0

这个问题可能属于superuser.com – Ither 2010-12-09 18:43:08

+0

啊。我不知道那件事。谢谢。我会在那里问我以下的问题。 – Ola 2010-12-09 19:31:27

Autohotkey附带一个名为Window Spy的程序。您可以使用它来发现活动窗口的标题。

另外,请注意ahk_class(在帮助文件中查找ahk_class),它使用窗口的类型而不是标题。 例如,在我的Win 7的情况下,我可以限制热键通过指定资源管理器:

#IfWinActive ahk_class CabinetWClass 

Windows资源管理器似乎在不同时间使用不同的窗口类(例如,如果搜索是显示或不 - 至少在Win XP中)。该脚本两类我见过的匹配和映射按Ctrl - 大号“专注地址栏”(ALA火狐)在资源管理器:

#IfWinActive ahk_class ExploreWClass 
^L:: 
#IfWinActive ahk_class CabinetWClass 
^L:: 
    Send {F6} 
return 
#IfWinActive