I think this is a very weird question, but anyway...
I have created two C# applications, himgr.exe
and cimgr.exe
. They're installed with Inno Setup, and copied to C:\Program Files [(x86)]\Imgr Suite
.
They're done to be used through a context menu entry at explorer.exe
, so I configured the installator to create a few keys in the registry:
[Registry]
Root: HKLM; Subkey: "SOFTWARE\classes\jpegfile\shell\Halve size"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\classes\jpegfile\shell\Halve size\command"; ValueType: string; ValueName: ""; ValueData: """{app}\himgr.exe"" ""%1"""
Root: HKLM; Subkey: "SOFTWARE\classes\pngfile\shell\Halve size"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\classes\pngfile\shell\Halve size\command"; ValueType: string; ValueName: ""; ValueData: """{app}\himgr.exe"" ""%1"""
Root: HKLM; Subkey: "SOFTWARE\classes\giffile\shell\Halve size"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\classes\giffile\shell\Halve size\command"; ValueType: string; ValueName: ""; ValueData: """{app}\himgr.exe"" ""%1"""
Root: HKLM; Subkey: "SOFTWARE\classes\jpegfile\shell\Resize to custom size"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\classes\jpegfile\shell\Resize to custom size\command"; ValueType: string; ValueName: ""; ValueData: """{app}\cimgr.exe"" ""%1"""
Root: HKLM; Subkey: "SOFTWARE\classes\pngfile\shell\Resize to custom size"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\classes\pngfile\shell\Resize to custom size\command"; ValueType: string; ValueName: ""; ValueData: """{app}\cimgr.exe"" ""%1"""
Root: HKLM; Subkey: "SOFTWARE\classes\giffile\shell\Resize to custom size"; Flags: uninsdeletekey
Root: HKLM; Subkey: "SOFTWARE\classes\giffile\shell\Resize to custom size\command"; ValueType: string; ValueName: ""; ValueData: """{app}\cimgr.exe"" ""%1"""
The full installation script is here.
Note: I also tried HKCR\jpegfile
etc. and it worked for me, but...
Neither using the script above (using HKLM
) nor with HKCR
, for some people it doesn't work. 4 people out of 6 who have tried it haven't had any problems and it has worked as intended, but for 2 people it hasn't.
The entries were at the registry, but there were no context menu entries.
For one of the testers, the Edit with GIMP entry of the jpegfile
key, although present in registry, wasn't shown in the context menu either. Also, for the same tester, the Preview entry for the context menu was shown twice.
In this thread you have more information about the program itself and the tests. A RAR file with all the files needed for the compilation of the installer is available here.
This is really worrying me, and we can't find any explanation for why is it not working.