LabVIEW报错-2147023537注册Com组件 点击:421 | 回复:0



fjczd

    
  • 精华:0帖
  • 求助:0帖
  • 帖子:552帖 | 36回
  • 年度积分:703
  • 历史总积分:1294
  • 注册:2008年8月14日
发表于:2023-03-20 19:49:14
楼主

LabVIEW报错-2147023537注册Com组件

LabVIEW在运行时,出现Error-2147221164,需要注册。可以参照如下的方法进行。

Error-2147221164 When Running an Application That Uses the Report Generation Toolkit

IssueDetails

I createdan application that uses the Report Generation VIs that ship with LabVIEW. Ithen installed the executable and LabVIEW Run-Time Engine on the Windowsmachine within the Administrator (local) account. However, when a user otherthan the Administrator logs in, the Report Generation VIs return the followingerror message:

Error-2147221164 occurred at Class not registered in <VI Name>.vi

If Iinstall the LabVIEW Run-Time Engine in the specific user account I am logged inon, the printing works well. It seems as though I must install the Run-TimeEngine on each user account to use the Report Generation VIs. How can I make itwork for any user without installing the Run-Time Engine on each account?

Solution

The veryfirst thing to check, when receiving this error, is if Microsoft Officeproducts, like Excel and Word, are installed on your computer. If you arereceiving this error with the products installed, follow the steps below on howto register the nireports.dll.

You mustregister the nireports.dll with the operating system.  On a Windows machine, you should:

Login asa non-Administrator.

Locatethe nireports.dll file located at <NationalInstruments>\shared\NI-Reports 

Go toStart>>Run and type regsvr32 "<NationalInstruments>\Shared\NI-Reports\nireports.dll".

Click theOK button.

Notes:The file path before <National Instruments> should be C:\Program Files\or C:\Program Files(x86)\ depending on your system type.

 

A smalldialog box should pop-up, indicating that the DLL properly registered with Windows.The operating system will give permission to all standard users to access thefile.

 

 

 

 

注册 COMActiveX 服务器

使用此过程注册任何 ActiveX 服务器或控件COM 服务器供应用程序使用。

在“root”属性中,选择“[System(32-bit)]”

将可执行文件路径设置为regsvr32.exe可执行文件的名称。

regsvr32.exe

在“参数”属性中,提供用于导入配置的参数:

/s“<file.dll>”

/s 标志可确保以静默方式执行寄存器。

其中<file.dll>替换为COM 服务器dll OCX 文件的路径和名称(如果它是ActiveX 控件)。

注意

若要注销 COM 对象,请使用/u 标志。

单击“确定”。

通过选择“构建”»“构建所有包”来构建所有包。

在执行安装后运行包安装程序时,将注册COM 对象。

Use thisprocedure to register any ActiveX Servers or Controls COM Servers for yourapplication to use.

In theRoot property, select [System (32-bit)].

Set theExecutable Path to the name of the regsvr32.exe executable.

regsvr32.exe

In theArguments property, provide the arguments to import your configuration:

/s“<file.dll>”

The /sflag ensures you will perform the register silently.

Where<file.dll> is replaced by the path and name of your COM Server dll or OCXfile if it is a ActiveX Control.

Note

To unregistera COM object use the /u flag.

Click OK.

Build allpackages by selecting Build » Build All Packages.

When yourpackage installer is run after the installation is executed, the COM Objectwill be registered.

Parenttopic: Executing Install and Uninstall Commands

Relatedtasks:

ExecutingInstall and Uninstall Commands

需要说明的是,上述的例程和文档,都是可以下载的,双击即可打开,其中压缩文件是可以采用粘贴复制的方式,拷贝到硬盘上。这不是图片,各位小伙伴看到后尝试一下,这个问题就不用加微信咨询了。有关LabVIEW编程、LabVIEW开发等相关项目,可联系们。附件中的资料这里无法上传,可去公司网站搜索下载。




楼主最近还看过


热门招聘
相关主题

官方公众号

智造工程师