This post is pretty simple, it's really to immortalize some pretty simple stuff that I seem to keep forgetting in my head. Blogging something has a tendency to sear things into my head.
Larry Wall once listed the three chief virtues of the programmer as: Laziness, Impatience and Hubris. This is really about the first quality. I downloaded Paint.NET the other day and wanted to be able to open certain types of content with Paint.NET with the context menu (see below). On some of my machines this either isn't available or doesn't work very well. This is how you add commands to the context menu for a given file type. To be clear we want the following behavior.
To pull this off is quite simple you first:
- Open Windows Explorer, click Tools->Folder Options->File Types(tab) scroll down to the file type you want to add the action for.
- After you have your type of file selected (ie. GIF) click Advanced.
- Click New to add a new Custom Action, give it a name and then an application to run. You can specify parameters using "%1" "%2" etc...
- It's important to put quotes (") around the parameters in case they happen to be in paths that involve white space. I won't really take the time to get in to DDE because I've never really gotten it to work consistently.
- Finally click OK and you should be off to the races.
Short but sweet,