Results 1 to 12 of 12

Thread: (Resolved) Help with Browser from Button Code...

Threaded View

  1. #1

    Thread Starter
    Member
    Join Date
    Dec 2004
    Posts
    34

    Resolved (Resolved) Help with Browser from Button Code...

    Ok, I have noticed that this code:

    VB Code:
    1. 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
    2.  
    3. Private Const SW_SHOWNORMAL = 1
    4.  
    5. Private Sub Command1_Click()
    6. ShellExecute Me.hwnd, vbNullString, "http://www.microsoft.com/", vbNullString, "C:\", SW_SHOWNORMAL
    7. End Sub
    8.  
    9. End Sub

    Returns this error statement when I go to compile it:

    "Only comments may appear after End Sub, End function, or End Property"

    and then it highlights this part:

    VB Code:
    1. 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

    Why am I receiving this message? What did I do wrong? Please help - Thanks
    Last edited by The Dude45; Dec 24th, 2004 at 11:48 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width