类未注册错误VB.NET 2008

类未注册错误VB.NET 2008,vb.net,vb6-migration,Vb.net,Vb6 Migration,你好, 我已将一个VB6项目转换为VB.NET2008 其中一个表单在设计模式中抛出以下错误。 类未注册(HRESULT的异常:0x80040154(REGDB_E_CLASSNOTREG)) 这是调用堆栈: 在System.Windows.Forms.UnsafeNativeMethods.CoCreateInstance(Guid和clsid、对象punkOuter、Int32上下文、Guid和iid) 位于System.Windows.Forms.AxHost.CreateWithOutl

你好, 我已将一个VB6项目转换为VB.NET2008 其中一个表单在设计模式中抛出以下错误。 类未注册(HRESULT的异常:0x80040154(REGDB_E_CLASSNOTREG)) 这是调用堆栈:

在System.Windows.Forms.UnsafeNativeMethods.CoCreateInstance(Guid和clsid、对象punkOuter、Int32上下文、Guid和iid) 位于System.Windows.Forms.AxHost.CreateWithOutlineCense(Guid clsid) 位于System.Windows.Forms.AxHost.CreateInstanceCore(Guid clsid) 在System.Windows.Forms.AxHost.CreateInstance()中 在System.Windows.Forms.AxHost.GetOcxCreate()中 在System.Windows.Forms.AxHost.set_站点(ISite值) 在System.ComponentModel.Container.Add处(IComponent组件,字符串名称) 位于System.ComponentModel.Design.DesignerHost.Add(IComponent组件,字符串名称) 位于System.ComponentModel.Design.DesignerHost.System.ComponentModel.Design.IDesignerHost.CreateComponent(类型componentType,字符串名称) 位于System.ComponentModel.Design.Serialization.DesignerSerializationManager.CreateInstance(类型类型、ICollection参数、字符串名称、布尔addToContainer) 位于System.ComponentModel.Design.Serialization.DesignerSerializationManager.System.ComponentModel.Design.Serialization.IDesignerSerializationManager.CreateInstance(类型类型、ICollection参数、字符串名称、布尔addToContainer) 位于System.ComponentModel.Design.Serialization.CodeDomainSerializerBase.DeserializeInstance(IDesignerSerializationManager管理器,类型类型,对象[]参数,字符串名称,布尔addToContainer) 位于System.ComponentModel.Design.Serialization.ComponentCodeDomainSerializer.DeserializeInstance(IDesignerSerializationManager管理器,类型类型,对象[]参数,字符串名称,布尔addToContainer) 位于System.ComponentModel.Design.Serialization.CodeDomainSerializerBase.DeserializeExpression(IDesignerSerializationManager管理器,字符串名称,CodeExpression) 位于System.ComponentModel.Design.Serialization.CodeDomainSerializer.DeserializeStatementToInstance(IDesignerSerializationManager,CodeStatement语句) 位于System.ComponentModel.Design.Serialization.CodeDomainSerializer.Deserialize(IDesignerSerializationManager,对象codeObject) 在System.Windows.Forms.Design.ControlCodeDomainSerializer.Deserialize(IDesignerSerializationManager,Object codeObject)中 位于System.ComponentModel.Design.Serialization.TypeCodeDomainSerializer.DeserializeName(IDesignerSerializationManager管理器、字符串名称、CodeStatementCollection语句)

我将项目中的DLL复制到system 32,并使用visual studio命令行工具使用Regasm.exe进行注册,以确保所有DLL都已注册。 但问题依然存在。我还有什么办法可以让这一切顺利进行吗?
请给出建议。

我对这个解决方案不是很确定,但在项目属性中我添加了引用路径。这样应用程序就知道在哪里查找程序集了,而且它工作了

调用regasm时是否使用了
codebase
参数?您的项目是否碰巧设置为以任何CPU为目标?尝试将其设置为目标X86(项目设置->编译->高级编译选项),看看这是否解决了问题。@sharptooth这到底有什么关系?抱歉,我帮不上什么忙。我遇到了一个类似的问题,改变目标为我解决了这个问题。