View Single Post
  #13   Report Post  
Posted to microsoft.public.excel.programming
GS[_2_] GS[_2_] is offline
external usenet poster
 
Posts: 3,514
Default VBA Code== Goto a webpage using a command button in a UserForm

If anyone is interested in a reusable process that's not application
object dependant...

Private Declare Function ShellExecute Lib "shell32.dll" _
Alias "ShellExecuteA" (ByVal hwnd As Long, _
ByVal lpOperation As String, ByVal lpFile As String, _
ByVal lpParameters As String, ByVal lpDirectory As String, _
ByVal nShowCmd As Long) As Long


Sub OpenUrl(Url$)
' Opens the specified URL in the user's default browser
ShellExecute 0&, vbNullString, _
Url, _
vbNullString, vbNullString, vbNormalFocus
End Sub

--
Garry

Free uenet access at http://www.eternal-september.org
Classic VB Users Regroup
comp.lang.basic.visual.misc
microsoft.public.vb.general.discussion