Is it possible to open a Windows Explorer window from PowerShell?

后端 未结 10 529
小鲜肉
小鲜肉 2020-12-07 07:21

I\'m sure this must be possible, but I can\'t find out how to do it.

Any clues?

10条回答
  •  死守一世寂寞
    2020-12-07 07:44

    $startinfo = new-object System.Diagnostics.ProcessStartInfo 
    $startinfo.FileName = "explorer.exe"
    $startinfo.WorkingDirectory = 'D:\foldername'
    
    [System.Diagnostics.Process]::Start($startinfo)
    

    Hope this helps

提交回复
热议问题