Some Windows programs can use different icons for different files with the same extension.
Example
- .sln can show a different icon depending on what version of Visual Studio the solution was made in (actually, determined by the version number in the top line in the .sln)
- Photoshop .psd files have icons with a thumbnail of the image
- A .url shortcut file has the page's favicon if opened in, or saved from, Internet Explorer
I'm guessing it must be custom to that computer only. On a box without Visual Studio installed, .sln files just have the default 'I don't know this program' icon. Is there something that needs to be changed in the registry?
How can I do this? I'd like to have the option of associating custom icons with files to my own programs.
[Edit] I really with I could do this in managed code. It's possible (<SDK v1.1>\Samples\Technologies\Interop\Applications\ShellCmd) but it also appears to be potentially dangerous and the wrong tool for the job in practice: http://social.msdn.microsoft.com/forums/en-US/netfxbcl/thread/1428326d-7950-42b4-ad94-8e962124043e/. I really hoped MS would have a good managed API for this kind of stuff by now.