Results 1 to 6 of 6

Thread: Webbrowser 'Custom Right Click Menu' on Vista

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jan 2010
    Location
    Obuasi
    Posts
    151

    Resolved Webbrowser 'Custom Right Click Menu' on Vista

    i tried the 'Custom Right Click Menu' tutorial by wiz126

    these are the codes

    VB Code:

    1. 'Must Add Microsoft HTML Object Library
    2. Option Explicit
    3. Public WithEvents HTML As HTMLDocument
    5. Private Function HTML_oncontextmenu() As Boolean
    6. HTML_oncontextmenu = False
    7. PopupMenu mnu '<---Check the mnu to your own menu name
    8. End Function
    9.
    10.Private Sub Form_Load()
    11.WebBrowser1.Navigate "www.google.com"
    12.End Sub
    13.
    14.Private Sub Form_Unload(Cancel As Integer)
    15.Set HTML = Nothing
    16.End Sub
    17.Private Sub WebBrowser1_DocumentComplete(ByVal pDisp As Object, _
    18.URL As Variant)
    19.Set HTML = WebBrowser1.Document
    20.End Sub

    ____

    my problem is that it is not working and i don't know why.
    am using windows Vista, has it got something to do with it?
    Last edited by jeffrey4u; Jul 16th, 2010 at 05:29 AM.
    There's only one thing that makes a dream impossible to achieve: THE FEAR OF FAILURE

  2. #2
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Webbrowser 'Custom Right Click Menu' on Vista

    What does "not working" mean?

    Do you get an error?
    Do you get nothing at all?
    How are you attempting to run the PopUpMenu line?

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Jan 2010
    Location
    Obuasi
    Posts
    151

    Re: Webbrowser 'Custom Right Click Menu' on Vista

    yeah, am trying to run the popup line and it's not showing at all.
    Nothing is shown when i press the right-click button
    There's only one thing that makes a dream impossible to achieve: THE FEAR OF FAILURE

  4. #4
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: Webbrowser 'Custom Right Click Menu' on Vista

    From where are you running the popupmenu code?

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Jan 2010
    Location
    Obuasi
    Posts
    151

    Re: Webbrowser 'Custom Right Click Menu' on Vista

    yes.
    when i right-click on the mouse, menu was suppose to popup but nothing is coming
    There's only one thing that makes a dream impossible to achieve: THE FEAR OF FAILURE

  6. #6

    Thread Starter
    Addicted Member
    Join Date
    Jan 2010
    Location
    Obuasi
    Posts
    151

    Re: Webbrowser 'Custom Right Click Menu' on Vista

    yes.
    when i right-click on the mouse, the menu was suppose to popup but nothing is coming (with the code at line 7)
    There's only one thing that makes a dream impossible to achieve: THE FEAR OF FAILURE

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