locked
Installing a COM compatible assembly from a CAB via IE RRS feed

  • Question

  • I have a .NET assembly written in C# that is COM compatible.  This assembly is going to be used by a legacy web application that uses ActiveX controls embedded in ASP.  If I register the assembly with RegAsm /codebase, everything is fine, and I can access it from the ActiveX controls.  However, all of the ActiveX controls are deployed in CAB files, and I want to distribute this assembly in a CAB file as well.  I have tried various things, but I can't get the assembly to properly register from a CAB file.

     

    Among other things, I tried running RegAsm /regfile to see what entries should be made in the registry.  Then I added the equivalent entries under the [AddToRegistry] section in the INF.  For example:

     

    In the .reg file:

     

    [HKEY_CLASSES_ROOT\MyNamespace.MyClass\CLSID]

    @="{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}"

     

    In the INF:

     

    HKCR,"MyNamespace.MyClass\CLSID",,0x00000000,"{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}"

     

    Not only is the registry not modified, but the file does not even copy.  Without the registry settings, I have at least been able to get the assembly DLL to copy to the correct directory.

     

    One last thing -- the COM compatible assembly is dependent on one other custom .NET assembly that is not COM compatible.  This doesn’t seem to be a problem at runtime.  As I said, registering the COM compatible assembly with RegAsm /codebase and putting the other assembly in the same directory works.  I don't know if it could causing a problem with installation from a CAB, though.

     

    Can anyone help?

    Wednesday, January 7, 2009 3:32 PM

Answers