Home All Groups Group Topic Archive Search About

axWebBrowswer Context Menu (VB 2003)

Author
21 Feb 2006 6:05 PM
SteMc
I've got the axWebBrowser in my program and I wish to add a context
menu. When the program runs there is a default context menu, but I
don't want this. I either want to change the existing context menu or
create my own, but I don't know how.

I've looked in the properties for the broswer, but there doesn't seem
an option for context menu :(

I've also tried setting the context menu by typing
"axWebBrowser1.contextmenu = contextmenu1" but this seems to have no
effect.

Can anyone help me?

Steve

Author
21 Feb 2006 7:11 PM
CMM
Not sure how well it works in VB.NET, but I think (if I remember correctly)
you should be able to do this using the WebCustomizer.dll from Microsoft.
http://msdn.microsoft.com/archive/default.asp?url=/archive/en-us/samples/internet/browser/WBcustomizer/default.asp

Or do a search on Google and MSDN for webcustomizer.dll for more details.

--
-C. Moya
www.cmoya.com
Show quoteHide quote
"SteMc" <goo***@jasmonio.supanet.com> wrote in message
news:1140545145.682720.308550@g44g2000cwa.googlegroups.com...
> I've got the axWebBrowser in my program and I wish to add a context
> menu. When the program runs there is a default context menu, but I
> don't want this. I either want to change the existing context menu or
> create my own, but I don't know how.
>
> I've looked in the properties for the broswer, but there doesn't seem
> an option for context menu :(
>
> I've also tried setting the context menu by typing
> "axWebBrowser1.contextmenu = contextmenu1" but this seems to have no
> effect.
>
> Can anyone help me?
>
> Steve
>
Author
22 Feb 2006 6:32 AM
m.posseth
In the past you could do this with the wbcustomizer.dll   or by subclassing
the control ( i prefered subclassing )

a good alternative in VB.net is a message filter to intercept the messages
send to the control and react with your custom action

see this example http://www.freevbcode.com/ShowCode.Asp?ID=5635 i once wrote

regards

Michel Posseth [MCP]





Show quoteHide quote
"SteMc" <goo***@jasmonio.supanet.com> schreef in bericht
news:1140545145.682720.308550@g44g2000cwa.googlegroups.com...
> I've got the axWebBrowser in my program and I wish to add a context
> menu. When the program runs there is a default context menu, but I
> don't want this. I either want to change the existing context menu or
> create my own, but I don't know how.
>
> I've looked in the properties for the broswer, but there doesn't seem
> an option for context menu :(
>
> I've also tried setting the context menu by typing
> "axWebBrowser1.contextmenu = contextmenu1" but this seems to have no
> effect.
>
> Can anyone help me?
>
> Steve
>
Author
14 Mar 2006 2:55 PM
Charles Law
Steve

Have a look at the reply to your other post, and in the sample search for
the word 'context'. There is a comment stating how to disable the built-in
context menu. At the same time, you can modify it or add your own.

HTH

Charles


Show quoteHide quote
"SteMc" <goo***@jasmonio.supanet.com> wrote in message
news:1140545145.682720.308550@g44g2000cwa.googlegroups.com...
> I've got the axWebBrowser in my program and I wish to add a context
> menu. When the program runs there is a default context menu, but I
> don't want this. I either want to change the existing context menu or
> create my own, but I don't know how.
>
> I've looked in the properties for the broswer, but there doesn't seem
> an option for context menu :(
>
> I've also tried setting the context menu by typing
> "axWebBrowser1.contextmenu = contextmenu1" but this seems to have no
> effect.
>
> Can anyone help me?
>
> Steve
>