Exemple #1
0
 private static void RemoveFileAssociation(FileAssociation fileAssociation, DefinitionIdentity subId, string productName)
 {
     using (RegistryKey classesKey = Registry.CurrentUser.OpenSubKey("Software\\Classes", true))
     {
         if (classesKey == null)
         {
             return;
         }
         Logger.AddMethodCall("RemoveFileAssociation(" + fileAssociation.ToString() + ") called.");
         ShellExposure.RemoveFileAssociationExtentionInfo(fileAssociation, subId, classesKey, productName);
         string clsIdString = ShellExposure.RemoveFileAssociationProgIDInfo(fileAssociation, subId, classesKey, productName);
         if (clsIdString == null)
         {
             return;
         }
         ShellExposure.RemoveFileAssociationCLSIDInfo(fileAssociation, subId, classesKey, clsIdString, productName);
     }
 }