Re: How difficult is to add my menu to Windows Explorer?



You can add a basic Shell menu easily. Pick the
file type and add a few Registry keys. The following
adds Open with Notepad for all files:

HKEY_CLASSES_ROOT\*\shell\Open with Notepad\
default value: "Open with Notepad"

HKEY_CLASSES_ROOT\*\shell\Open with Notepad\Command\
default value: "notepad.exe %1"

The default value of the "Open with Notepad" key (which can
be named anything) is what displays on the menu. In other
words, this:

HKEY_CLASSES_ROOT\*\shell\blah\
default value: "Open with Notepad"

will still display "Open with Notepad"

You can also add the keys under the file type key. For
instance, you can add it under HKCR\.txt or HKCR\txtfile.
But if you use HKCR\txtfile and an editor is later installed
that takes over .txt then the HKCR\.txt key may lead to
the HKCR\AcmeTextFile key, disabling your menu.

And you can have a menu for folders by doing the same
thing under the HKCR\folder or HKCR\directory key.

By adding the line: yourEXEpath %1 your program gets
the selected file path in the command line at startup. So
you just have to check in Sub Main or Form load:

s = Command$

Then check that at startup to see if you've got a file path.

You can also add a menu item under the shellex key instead
of the shell key. Your menu item then shows lower down on
the context menu. But for that you need to write a context menu
handler shell extension. The advantages are questionable.The
main difference seems to be that you get to customize your
menu text for the specific file. If you're interested in that you
might want to look for the book V. B. Shell Programming by
J.P. Hamilton (O'Reilly). It covers all of the shell extensions
clearly. They're not hard to do from VB but I don't know of
any usable documentation about *how* to do it other than
that book.

Hello group,
I need some pointers where to start.
I would like to add my own menu to Windows Explorer popup menu depending
on
the object clicked on by the user.
How difficult is it?
Can I see some examples how to do that?
Thanks,
Kathy




.



Relevant Pages

  • Re: How difficult is to add my menu to Windows Explorer?
    ... Are those Shell menus or belonging to each application indepedently? ... The only commonality is that Explorer and Notepad ... In IE/Web Browser control there used to be functionality ... received some requests for my app to add popup menu to other app windows ...
    (microsoft.public.vb.general.discussion)
  • Re: How difficult is to add my menu to Windows Explorer?
    ... Are those Shell menus or belonging to each application indepedently? ... The only commonality is that Explorer and Notepad ... In IE/Web Browser control there used to be functionality ... scripted thruogh the DOM, so it would require accessing the ...
    (microsoft.public.vb.general.discussion)
  • Re: Custom Shell Running Twice On Boot
    ... I replaced my shell with notepad and got 2 instances of it. ... Silent DX9.0c + managed extensions setup ...
    (microsoft.public.windowsxp.embedded)
  • Re: How difficult is to add my menu to Windows Explorer?
    ... adding to shell menu my menu which will mimic Windows 'Copy' menu. ... default value: "Open with Notepad" ... handler shell extension. ...
    (microsoft.public.vb.general.discussion)
  • RE: Notepad displays in tray but wont open
    ... not sure how to open in safe mode and then what to do. ... can i delete notepad and reinstall? ... On Edit File Type be sure these entries there: ... Click on Edit. ...
    (microsoft.public.windowsxp.help_and_support)

Loading