在PowerShell中实例化chrome对象

use*_*251 21 powershell google-chrome instantiation

我有一个PowerShell脚本在IE中运行得很好但是我需要在Chrome中使用它.$ ie = new-object -com"InternetExplorer.Application"适用于IE.如何实例化Chrome浏览器?

Jim*_*Jim 27

您可以按名称启动进程,甚至可以传递一个参数,如下所示:

Start-Process "chrome.exe" "www.google.com"
Run Code Online (Sandbox Code Playgroud)