如何获得变量的subwindowtitle?

时间:2016-06-06 07:38:03

标签: powershell

使用窗口标题打印线程状态的应用程序, 所以我找到了如下的powershell脚本。

Get-Process |where {$_.mainWindowTitle} |format-table mainwindowtitle 

这是完美的脚本但应用程序有2个窗口,而MainWindowTitle只是对话框,但需要的信息不是那个。

当进程有2个窗口时,如何从powershell获取另一个windowtitle。

1 个答案:

答案 0 :(得分:0)

您可以尝试以下方法来获取子窗口:

Get-Process | where {$_.mainWindowTitle} | Get-ChildWindow