Code: Select all
#SC029:: { ; win + tilde
hwnd := WinExist("A")
for w in ComObject("Shell.Application").Windows
if w.hwnd = hwnd && DirExist(path := w.Document.Folder.Self.Path) {
Run A_ComSpec, path
return
}
Run A_ComSpec
}