title: RegDeleteKey fails with ERROR_ACCESS_DENIED
body: <p>Windows Mobile:<br>
  As the final step of unloading a driver, I am trying to delete the registry subkey (HKLM\Drivers\BuiltIn\XYZ) using RegDeleteKey API and it fails returning ERROR_ACCESS_DENIED code.</p>
  
  <p><code>
  Below are the steps I followed:<br>
  1. FindFirstDevice<br>
  2. Stored the key and needed values for later use in case I need to reload the driver (Used RegOpenKeyEx and RegQueryValueEx APIs)<br>
  3. DeactivateDevice<br>
  4. RegCloseKey<br>
  5. RegDeleteKey<br>
  </code></p>
  
  <p>Steps 1 thru 4 work pretty fine, however, step 5 fails. Please suggest.</p>