Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I want to add custom context menu options for certain file extensions (like .zip-files) for a program I'm developing. However on many (but not all) PCs my software is going to be installed on 7-Zip is installed as well and therefore [] is referring to [HKEY_CLASSES_ROOT\] in the registry.

As I don't want to tamper with the original 7-Zip installation I just want to add my context menu options on top. However entries in [\shell] are without effect and I don't know how I could link [] to [HKEY_CLASSES_ROOT\] because the default value of [] is already being used by 7-Zip.

Any help would be greatly appreciated :)

share|improve this question
See if you can find another extension for a file type that has the behavior you want and use it as a template for what you're trying to do. – martineau Sep 9 '13 at 18:32
The problem is that other examples I found don't do it like 7-Zip. For example Gimp just writes itself into [HKEY_CLASSES_ROOT\pngfile\shell] for its context menu entry for .pngs. It seems that 7-Zip sort of hijacks the .zip extension, and I don't know a workaround but need one... – Sebastian Sep 10 '13 at 8:53

If the .zip files are your only concern, you may safely use the [HKEY_CLASSES_ROOT\CompressedFolder] key.

This is because Windows natively uses this key for it's .zip-related functionality, and 3rd party software products (including 7zip) mostly tend to share this key with Microsoft. It allows the developers to add their own functionality while preserving the native Windows "folder-like" handling of .zip files.

It's weird though, that your [HKEY_CLASSES_ROOT\.zip] default value refers to [HKEY_CLASSES_ROOT\]. It is yet possible, that even those old versions set correct [HKEY_CLASSES_ROOT\CompressedFolder] entries - you'd have to check.

share|improve this answer
this is not exactly what i wanted. – eramit2010 Feb 4 '14 at 9:06

From what I observe on my computer, you may safely "hijack" the .zip extension.

I have installed WinZip before 7Zip, so it was WinZip that took over the .zip extension, while 7Zip left it strictly alone.

However, 7Zip still works perfectly for me for .zip files, because it also installs a general extension for all file-types which does catch .zip files (among others).

In effect, in my opinion 7Zip taking over also the .zip extension is an overkill.

share|improve this answer
but it will display context menu of only latest or say default app. i want to display context menu of both. – eramit2010 Jan 28 '14 at 10:45
It displays both. I have both WinZip and 7Zip displayed for .zip files : WinZip via HKEY_CLASSES_ROOT\.zip and 7Zip via its general extension. Another idea for you is to develop a general/catch-all extension without hijacking anything. The disadvantage will be that your handler will always be invoked for any right-click on ALL files (it can decide to display nothing for non-zip files). The advantage is that you touch nothing of 7Zip in the registry. – harrymc Jan 28 '14 at 11:35
i know about all extension but that is not proper solution for my problem. i want to add new entry in right click menu of .zip file using registry. i can do it by adding it in registry of default application. menu is not showing after installing another application. – eramit2010 Jan 28 '14 at 12:07
I have listed here the two solutions that I know about: hijacking the file-extension or catch-all. I don't know of a third solution. – harrymc Jan 28 '14 at 13:07
thanks for two solution but i already knew these. – eramit2010 Jan 28 '14 at 13:10

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .