Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I was inspired by my other question to try the following:

Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Classes\.sln]

[HKEY_CURRENT_USER\Software\Classes\.sln\shell]

[HKEY_CURRENT_USER\Software\Classes\.sln\shell\countlines]
@="countlines"

[HKEY_CURRENT_USER\Software\Classes\.sln\shell\countlines\command]
@="c:\\countlines\\countlines.exe" %1

This should be adding a context menu item named "countlines" that runs the "countlines.exe" command, but it doesn't work.

How does one add a context menu entry for a given file extension?

share|improve this question
    
Here's thinking that this is a dupe of the question linked to. OP should be adding this to that question via an edit, no? –  marcusw May 3 '10 at 19:18
    
@marcusw: doesn't appear a duplicate to me; if anything it's a more general case (in which case the other question can be closed as a duplicate of this one). –  quack quixote May 3 '10 at 19:26
add comment

1 Answer

up vote 1 down vote accepted

The default value of the .sln key should be something like VisualStudio.Launcher.sln. That's called the program ID (ProgID) and it's the key you should edit to change the context menu:

[HKEY_CURRENT_USER\Software\Classes\VisualStudio.Launcher.sln\shell]

A ProgID key always takes precedence, so any changes made to the extension key will be ignored when a ProgID is present. ProgIDs are mainly used to group extensions into logical file types.

share|improve this answer
    
@efotinis: slightly unrelated, but is that why jpegs are unaffected by these registry tweaks but avis are? –  quack quixote May 4 '10 at 10:08
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.