VBA打开Goog​​le Chrome在任务栏中打开

时间:2019-11-25 04:00:14

标签: excel vba google-chrome

我正在使用以下代码通过VBA在Chrome中打开网站,但是Chrome在任务栏中启动,并且我必须单击该图标才能打开实际的Chrome窗口。 我需要在代码中添加一些内容以最大化打开Chrome吗?

Private Sub CommandButton11_Click()
Dim chromePath As String
  chromePath = """C:\Program Files\Google\Chrome\Application\chrome.exe"""
  Shell (chromePath & " -url https://google.com")
  Unload Me
End Sub

0 个答案:

没有答案