Solved

how to disable the pop up menu in WebBrowser control??

Posted on 2000-04-12
4
194 Views
Last Modified: 2013-11-28
I am using the WebBrowser control in my program written in VB6.  Is there any way to disable the pop up menu in the WebBrowser control?(i.e do not display the pop up menu when I right click inside the control).
0
Comment
Question by:aimui
  • 2
4 Comments
 
LVL 28

Expert Comment

by:AzraSound
ID: 2710453
0
 

Accepted Solution

by:
negeon earned 50 total points
ID: 2710528
You can reference Microsoft HTML Object Library(MSHTML.tlb).We suppose your WebbrowseControl named "WB1".
Option Explicit
Private WithEvents oDocument As HTMLDocument
Private Sub WB1_DownloadComplete()
Set oDocument = WB1.Document
End Sub
Private Function oDocument_oncontextmenu() As Boolean
'Notice you can do what you want to do,you can simply place a "'" or "REM" or you own popup menu,do what you like,enjoy it.
End Function

0
 

Author Comment

by:aimui
ID: 2711133
Thanks.
Can I just left the function oDocument_oncontextmenu() empty If I don't want to display the menu?
Why the menu still been displayed in a dynamic html page contains three frames?
0
 

Author Comment

by:aimui
ID: 2711152
Thanks.
Can I just left the function oDocument_oncontextmenu() empty If I don't want to display the menu?
Why the menu still been displayed in a dynamic html page contains three frames?
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Read about why website design really matters in today's demanding market.
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

792 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question