[英]Runtime Callable Wrapper Class Not Registered
I have a dll called srxCOM.dll for titan-FTP, this dll was made for VB6. 我有一个名为srxCOM.dll的titan-FTP dll,该dll是为VB6创建的。 I want to use the dll in Visual Studio .NET, So I created a run-time callable wrapper using tblimp and called it srxCOMnet.dll.
我想在Visual Studio .NET中使用该dll,因此我使用tblimp创建了一个运行时可调用包装,并将其称为srxCOMnet.dll。 I've added the dll as a reference in my VS project and can access functions within it.
我已将dll作为参考添加到我的VS项目中,并且可以访问其中的函数。 Upon building the project I get this error,
建立专案后,我得到这个错误,
ERROR: CLSID {A82C6CF0-7B42-4ABD-AECB-987E298A41AF} failed due to the following error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG)). 错误:由于以下错误,CLSID {A82C6CF0-7B42-4ABD-AECB-987E298A41AF}失败:80040154未注册类(HRESULT的异常:0x80040154(REGDB_E_CLASSNOTREG))。
After some research I have tried: 经过一些研究,我尝试了:
I don't want to write my application in VB6, is there anything else I can try? 我不想用VB6编写应用程序,还有什么我可以尝试的吗?
I ended up using a different dll supplied by titanFTP. 我最终使用了titanFTP提供的其他dll。
I found this codeproject.com: 我找到了这个codeproject.com:
Primary interop assemblies can reference only other primary interop assemblies. 主互操作程序集只能引用其他主互操作程序集。 If your assembly references types from a third-party COM type library, you must obtain a primary interop assembly from the publisher before you can generate your primary interop assembly.
如果您的程序集引用了第三方COM类型库中的类型,则必须先从发布者处获取一个主互操作程序集,然后才能生成主互操作程序集。 If you are the publisher, you must generate a primary interop assembly for the dependent type library before generating the referencing primary interop assembly.
如果您是发布者,则必须在生成引用主互操作程序集之前为依赖类型库生成主互操作程序集。
See this link below 见下面的链接
codeproject Using-Unmanaged-VB-Code-in-NET NET中使用非托管VB代码的codeproject
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.