title: How to unload C++ Shell Extension DLL properly
body: <p>I  have <strong>shell extension dll</strong> written in C++ and COM
  The dll is registered and loaded into memory. My upgrade setup program will do the following:</p>
  
  <ul>
  <li>Unregister the shell extension dll, kill the explorer.exe</li>
  <li>Copy the later version of the shell extension dll (Step 2)</li>
  <li>Start t he explorer.exe</li>
  </ul>
  
  <p>It works fine. But the issue is:</p>
  
  <p>If the user opened any other applications ( Internet explorer, sometimes windows task manager, notepad etc),  the step <strong>Step 2</strong> is failing.</p>
  
  <p>Is there any way to close all shell extension dll hooks while upgrading the dll.</p>
  
  <p>In the dll I am using GetOverlayInfo, context menu, database connection etc</p>