Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/vb.net/14.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/cassandra/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
VB.NET和AutoDesk Inventor 11自定义问题_Vb.net_Visual Studio 2005_Vista64 - Fatal编程技术网

VB.NET和AutoDesk Inventor 11自定义问题

VB.NET和AutoDesk Inventor 11自定义问题,vb.net,visual-studio-2005,vista64,Vb.net,Visual Studio 2005,Vista64,我在网站和互联网上做了一些搜索,试图找到一个解决我试图创建的VB.NET应用程序问题的方法。不幸的是,我被一条错误消息难住了,它阻止了我继续进行任何Inventor自定义 Tools: Visual Studio 2005 sp1, Inventor 11 Stand Alone install OS: Windows Vista 64 sp1 我在SDK文件夹下安装了开发工具。然后,我在COM中的VB.NET项目中向名为AutoDesk Inventor对象库的组件添加了一个引用。在“我的项

我在网站和互联网上做了一些搜索,试图找到一个解决我试图创建的VB.NET应用程序问题的方法。不幸的是,我被一条错误消息难住了,它阻止了我继续进行任何Inventor自定义

Tools: Visual Studio 2005 sp1, Inventor 11 Stand Alone install
OS: Windows Vista 64 sp1
我在SDK文件夹下安装了开发工具。然后,我在COM中的VB.NET项目中向名为AutoDesk Inventor对象库的组件添加了一个引用。在“我的项目”的“参考”下显示为:

Reference Name: Autodesk Inventor Object Library
Type: COM
Version: 1.0.0.0
Copy Local: True
Path: C:\Users\rschmalt\Visual Studio 2005\Projects\
        InvTest\InvTest\obj\Debug\Interop.Inventor.dll
我的代码如下:

'Opens Inventor Apprentice session to read part numbers

Dim oApprentice As New Inventor.ApprenticeServerComponent
Dim asmDoc As Inventor.ApprenticeServerDocument
Dim refDoc As Inventor.ApprenticeServerDocument

asmDoc = oApprentice.Open(strIAMLocation)

For Each refDoc In asmDoc.ReferencedDocuments
  MessageBox.Show(refDoc.FullFileName.ToString)
Next
当我执行它时,我得到以下消息:

检索CLSID为{C343ED84-A129-11D3-B799-0060B0F159EF}的组件的COM类工厂失败,原因是以下错误:80040154

我曾尝试直接浏览到DLL(
Interop.Inventor.DLL
),然后它在引用中显示为.NET类型,但错误保持不变

vista 64(Inventor 11为32位)之间是否可能存在冲突?有什么建议吗?

看看这些

看看这些


有趣的是,我仔细研究了这一点,并选择了“corflags”选项。这不起作用,或者至少,我无法让它起作用(通过指向DLL)。然而,我进入了项目选项,编译,高级编译选项,目标CPU,并将其设置为x86-代码现在可以工作了!然而,这是否会给我的x64客户带来长期的问题?有趣的是,我仔细研究了这一点,并正在寻求“corflags”选项。这不起作用,或者至少,我无法让它起作用(通过指向DLL)。然而,我进入了项目选项,编译,高级编译选项,目标CPU,并将其设置为x86-代码现在可以工作了!但是,这是否会对我的x64客户造成长期问题?