View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Helmut Weber Helmut Weber is offline
external usenet poster
 
Posts: 15
Default Please Help - Trying to Launch IE from Excel

Hi "Bob",

in the word groups I answered that question, like that:

Sub Test2()
' Dim var
Dim s As String
s = "C:\Program Files\Internet Explorer\iexplore.exe"
s = Chr(34) & s & Chr(34)
s = s & "http://www.google.com"
Shell s
' or
' var = Shell(s)
End Sub

Yet Karl E. Peterson, who is quite an authority, told me:

"No, don't use that!
It's highly fragile, and of course won't be at all to the
user's pleasure if they use Firefox or Opera or something else
as the default browser. Here's the simple way to load a page in
whatever browser the user prefers:
http://vb.mvps.org/samples/HyperJmp"

Make the best of all of it.