I'm checking the registry key HKEY_CLASSES_ROOT\CLSID\{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}\InprocServer32 to see if a managed .NET DLL is registered.
The Guid (x's) I'm getting from
public static string AssemblyClassIDString(System.Reflection.Assembly assembly)
{
object[] objects = assembly.GetCustomAttributes(typeof(System.Runtime.InteropServices.GuidAttribute), false);
if (objects.Length > 0)
{
return ((System.Runtime.InteropServices.GuidAttribute)objects[0]).Value;
}
else
{
return String.Empty;
}
}
The function returns a GUID but not the one matching the one inside the registry under CLSID. Does anyone know why this doesn't work?
Thanks