Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I'd recommend following my stack overflow post located <a href="https://stackoverflow.com/questions/2993118/how-to-perform-shell-icon-embedding-in-visual-studio-2010">here</a> for the simplest and most elegant way of embedding icons into a resource without the need for a c++ project in a managed .NET application.</p> <p>Next, here is the proper way to set this via wix:</p> <pre><code> &lt;Component Id="stackoverflowFileRegistration" Guid="MY_GUID"&gt; &lt;RegistryKey Root="HKCR" Key=".stackoverflow" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes"&gt; &lt;RegistryValue Value="stackoverflow.Document" Type="string" KeyPath="yes" /&gt; &lt;RegistryValue Name="Content Type" Value="application/stackoverflow" Type="string" /&gt; &lt;RegistryKey Key="ShellNew" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes"&gt; &lt;RegistryValue Name="NullFile" Value="" Type="string" /&gt; &lt;RegistryValue Name="Data" Value="Default new document Content.. NOTE: you must use a MutiStringValue nodes for multi-line content...." Type="string"/&gt; &lt;/RegistryKey&gt; &lt;/RegistryKey&gt; &lt;RegistryKey Root="HKCR" Key="stackoverflow.Document" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes"&gt; &lt;RegistryValue Value="stackoverflow Document" Type="string" /&gt; &lt;RegistryKey Key="DefaultIcon" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes"&gt; &lt;RegistryValue Value="[INSTALLDIR]bin\stackoverflow.lib.dll, 1" Type="string" /&gt; &lt;/RegistryKey&gt; &lt;RegistryKey Key="Shell" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes"&gt; &lt;RegistryKey Key="openstackoverflowwebsite" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes"&gt; &lt;RegistryValue Value="Open Stackoverflow" Type="string" /&gt; &lt;RegistryKey Key="command" ForceCreateOnInstall="yes" ForceDeleteOnUninstall="yes"&gt; &lt;RegistryValue Value="&amp;quot;[INSTALLDIR]stackoverflow.exe&amp;quot; /openwebsite &amp;quot;%1&amp;quot;" Type="string" /&gt; &lt;/RegistryKey&gt; &lt;/RegistryKey&gt; &lt;/RegistryKey&gt; &lt;/RegistryKey&gt; &lt;/Component&gt; </code></pre> <p>This sample registers the default icon for a specific file extension (.stackoverflow) that is located in an assembly from step 1. It also shows how to create Windows Explorer associated right click commands as well as adds a menu item to the Windows Explorer New sub menu.</p> <p>Thanks</p> <p>-Blake Niemyjski</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload