Dmitry Kostochko

Video HowTo: Customize main and context menus in Internet Explorer (VB.NET)

Apart from Explorer bar there are a few more things that can be easily customized in Internet Explorer and today we will look into the customization of main menu and context menus. Yes, you can modify them by adding your own menu items.

Things are plain and straightforward when it comes to Internet Explorer main menu. You can add your menu items to the native IE menu under File, Edit, View, Tools and Help. When a context menu is concerned, it is a bit more complicated – you need to know the web-page context type for which your custom context menu item is going to be displayed. But it is not a big complexity because the number of context types is limited and you can select all contexts after all :)

Let's see how it works:

This sample video was captured in Visual Studio 2008 (VB.NET) with Add-in Express 2010 for Internet Explorer and .net.

You may also be interested in:

Adding a custom item to the IE main menu
Building Explorer bars and context menu
Creating an IE add-on step-by-step

3 Comments

  • https://secure.gravatar.com/avatar/2cb61ec590aad8d34884749b2e466e81?s=32&d=https%3A%2F%2Fsecure.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D32&r=G anju says:

    Hi,

    I am using add in express for IE . I want to get selected text in the webpage to a variable using add in express in vb.net .Is it possible ? I can select the text in the webpage using ADXIEMenuContexts.mcTextSelection . Is it possible to get the selected text to a variable
    like Dim Str as string = ADXIEMenuContexts.mcTextSelection.ToString

    Thanks .
    Anju

  • https://secure.gravatar.com/avatar/29957f26ad2d8ba527fd9cc8cfa7b2e0?s=32&d=https%3A%2F%2Fsecure.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D32&r=G Andrei Smolin (Add-in Express Team) says:

    Anju,

    The IE module provides the HTMLDocument property. You get the selection using Me.HTMLDocument.selection (this.HTMLDocument.selection in C#).

  • https://secure.gravatar.com/avatar/ad516503a11cd5ca435acc9bb6523536?s=32 Anonymous says:

    thanks

Post a comment

Have any questions? Ask us right now!