自学内容网 自学内容网

Windows上LabVIEW编译生成可执行程序

      LabVIEW项目浏览器(Project Explorer)中的"Build Specifications"就是用来配置项目发布方法的。在"Build Specifications"右键菜单中选取"New",可以看到程序有几种不同的发布方法:Application(EXE)、Installer、.Net Interop Assembly、Packed Library、Shared Library(DLL)、Source Distribution、Zip File。

      以下为操作步骤:实现简单加、减、乘、除功能

      1.打开NI LabVIEW 2024 Q1(32-bit):

      (1).点击"Create Project": 点击"Blank Project" --> 点击"Finish"

      (2).File --> Save:文件名输入:calculator.lvproj,如下图所示:

      2.点击"My Computer",右键 --> New --> NI:保存名字为main.vi,添加两个数的加、减、乘、除操作,结果如下图所示:

      3.点击"Build Specifications":点击"New" --> "Application(EXE)"

      (1).Information:Build specification name:调整为Calculator;Target filename:调整为Calculator.exe;

      (2).Source Files:选中Project Files下的main.vi;点击Startup VIs的"->"

      (3).点击"Build",结果如下图所示:

      4.修改vi后,重新生成exe:点击"Build Specifications"下的"Calculator",点击右键选择"Build"

      5.在E:\GitCode\LabVIEW_Test\demo\builds\calculator\Calculator目录下生成的文件包括:Calculator.aliases、Calculator.exe、Calculator.ini,双击Calculator.exe,如下图所示:

      GitHubhttps://github.com/fengbingchun/LabVIEW_Test


原文地址:https://blog.csdn.net/fengbingchun/article/details/140438251

免责声明:本站文章内容转载自网络资源,如本站内容侵犯了原著者的合法权益,可联系本站删除。更多内容请关注自学内容网(zxcms.com)!