Skip to content

Commit

Permalink
stabilized RemoveAdd-in
Browse files Browse the repository at this point in the history
  • Loading branch information
arcgisprosdk committed Mar 18, 2016
1 parent e7ff3d8 commit 321754c
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions Framework/RemoveAddins/RemoveAddins/Utils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -50,17 +50,10 @@ public static List<string> GetAddInFolders()
localKey = RegistryKey.OpenBaseKey(Microsoft.Win32.RegistryHive.CurrentUser, RegistryView.Registry64);
esriKey = localKey.OpenSubKey(regPath);
}
if (esriKey == null)
{
//this is an error
throw new System.InvalidOperationException(err1);
}

foreach (var key in esriKey.GetValueNames())
{
myAddInPathKeys.Add(key.ToString());
}

if (esriKey != null)
myAddInPathKeys.AddRange(esriKey.GetValueNames().Select(key => key.ToString()));

}
catch (InvalidOperationException ie)
{
Expand All @@ -73,7 +66,7 @@ public static List<string> GetAddInFolders()
}

return myAddInPathKeys;

}
}
}

0 comments on commit 321754c

Please sign in to comment.