Jump to content

Can't launch the compiled EXE from the development machine (The VI is not executable...)


Recommended Posts

Bonjour,

I use Labview 2015 32-bit on a 64-bit Win& pro computer.  My application connects to Hardware using NI-VISA and NI-DAQmx only (Two RS232 communications via a VCOM port and one NI DIO card using DAQmx).  

Until today, I was building an executable which  I was copying through the network on another win7 pro machine in the lab next to the hardware.  It was working fine with Labview Runtime 2015 installed on this machine along with NI-VISA and NI-DAQmx.  I never used an installer, I installed those 3 components seperatly.

Yesterday I added some features to the application and the EXE won't start.  I have an error msg saying "The VI is not executable. The full version of Labview is needed to fix errors".  The machine in the lab can't run the EXE but the EXE won't even start on my development machine.  

  • My previous EXE from last week still works fine.
  • The code works fine with all new features if I run the main VI from the development environment.
  • I've double check all of my licences status.
  • If I open another project and compile the EXE, I am able to run this EXE (I use a complex app containing almost all the same software components)
  • If I build an EXE with a different UI source file part of the same project, that EXE works fine.
  • If I build the EXE from my previous version again, it works fine too.
  • I tried removing all the new features I had added in the project and build the EXE again and I still get the error.
  • I tried creating a new project file and import the same librairies to try building an EXE from a fresh project file and I still get the error.
  • I tried installing Labview 2015 on another computer and try to build an exe from a fresh labview install on this computer and I get the same error. The development machine can't execute the compiled EXE)

It has to be related to the code but, I can't roll-back and get functionality of the EXE again unless I totally replace all of my files from a backup made last month.  The most recent posts I read from a similar error are from 2013 and later.  And the problem described is always that the EXE does not work on the deployment machine but works fine on the development machine.  I must be at version 25 of this application to which I add improvements on a regular basis since almost 1 year.   I am really puzzled.  Is there a way to analyse or get more info about the broken EXE error?  All the new features I added are using components that were already present in the project and in the main VI.  The new features are important, I'd really like to use this working code with the hardware as soon as possible but I don't really want to install labview on the development machine.

Any ideas? I don't know what to try next.  What would be the best information to provide / look for for the next step?

Thanks to all in advance
Nien

Link to post
Share on other sites
6 hours ago, Nienscecco said:

Any ideas?

Please please please start using source control other than a monthly backup. Go to https://www.sourcetreeapp.com/, install it, and create a new repo "add" a working copy option. Everything is embedded, no separate server is necessary, you're just comitting changes locally. Its 5-10 minutes to set up, then all you have to remember to do is to commit occasionally -- I do it like every hour, some people prefer when they finish a feature, but in any case its easy and simple and would solve this problem in the future.

 

OK, so now to try to fix the issue. My first thought is to try to enable debugging in the exe, and then connect your labview debugger to it. This may not work since its broken from the start, but is worth a try:
http://zone.ni.com/reference/en-XX/help/371361N-01/lvhowto/debug_apps_dlls/
http://digital.ni.com/public.nsf/allkb/8DA679805915DE40862572D5007B2F70

If that fails, on the "additional exclusions" tab of a build spec there is a series of checkboxes. These would be better labelled as "toggle randomly to fix build" rather than the existing names. As mentioned, please toggle them randomly and see if it fixes the build. On the advanced tab, there is an option for using 8.x file layout. Same basic idea.

Link to post
Share on other sites

Thank you for your suggestions.  I will try that.  

I totally agree with you on the source control part.  I just arrived (more than one year, but believe me things are moving slow when you work for the governement...) in a government agency research group...  The persone before me has been doing things on his own for 20 years without source control and no real backup solutions. To implement a source control solution here is a huge quest.  To have access to a server or even get admin rights to a machine which is connected to the network is a contract I need to sign with my own blood (when there is a possibility at all).  I am familiar with Tortoise/SVN but I've never setup a server myself.  I will visit the link you posted.  Let's just hope I would be able to have the permission to install it on my development machine.

Again, thanks for your suggestions.  I may have to wait until 2 days before I can try that thouhg.  My work priorities are changing quickly here. :O) 

Link to post
Share on other sites

If that fails, on the "additional exclusions" tab of a build spec there is a series of checkboxes. These would be better labelled as "toggle randomly to fix build" rather than the existing names. As mentioned, please toggle them randomly and see if it fixes the build. On the advanced tab, there is an option for using 8.x file layout. Same basic idea.

Smithd, you are my new Hero! Your insights were right on!

As expected, debugging the EXE did not work because it was broken right from the start.  The connection was occuring though but the exe only showed a broken arrow (That is usually hidden when my application runs normally) and nothing happened if I clicked on it. But still I was having a disconnection warning when closing the broken EXE...

The solution came with your second suggestion.  Adding a checkmark to "Disconnect type definitions" from the Additional Exclusions tab fixed the build.  It makes sense to me because I remember I accidently saved a typedef double during my most recent modifications. I thought I had corrected myself and deleted the double from the disk and from the project but obviously something slipped through my fngers.

I spent the rest of my day learning about Git, GitHub and SourceTree.  I will probably stick to Subversion though.  It's well overdue that I finally implement a source control solution in here!

Problem solved.  Thanks again!!

  • Like 1
Link to post
Share on other sites
2 hours ago, Nienscecco said:

I spent the rest of my day learning about Git, GitHub and SourceTree.  I will probably stick to Subversion though.  It's well overdue that I finally implement a source control solution in here!

Problem solved.  Thanks again!!

Glad that worked. And yeah, the sourcetree/git was only because its available even from a single machine without setting up a server. The other differences between git and svn aren't sufficient to get worked up over.

  • Like 1
Link to post
Share on other sites
3 hours ago, Nienscecco said:

Adding a checkmark to "Disconnect type definitions" from the Additional Exclusions tab fixed the build.  It makes sense to me because I remember I accidently saved a typedef double during my most recent modifications. I thought I had corrected myself and deleted the double from the disk and from the project but obviously something slipped through my fngers.

Have a skim through this thread, which discusses some of the quirks of type definition disconnection: https://forums.ni.com/t5/LabVIEW/Application-Builder-What-does-quot-disconnect-type-definitions/td-p/2992511 

  • Like 1
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Similar Content

    • By Yaw Mensah
      I have installed Labview 2020 on Dedian Buster using the rpm to deb conversion method via alien. Due to Architecture mismatch i deleted the *i386.rpm files before conversion.
      My Problem is that after creating a project at "Build Specification"-> "rigth click" i am only able to select "Source Distribution". Application does not show up as an option. 
      I will be grateful for any suggestions.
      Thank you in advance.
    • By David_L
      Hey all,
      (Cross-post from ni.com forums)
      We have a LabVIEW application, which has a LabVIEW-based Installer.  This LabVIEW installer is called from within another Inno installer (since our main Inno installer pulls together multiple components, most of them not LabVIEW).  Whenever this Inno installer ends, it always asks the user to restart their PC, even if the LabVIEW installer was cancelled.
      I narrowed it down, and it's reproducible with only the LabVIEW installer, so it's definitely LabVIEW installer's fault.  According to Inno's help documentation, "if a program executed in the [Run] section queues files to be replaced on the next reboot (by calling MoveFileEx or by modifying wininit.ini), Setup will detect this and prompt the user to restart the computer at the end of installation."  However, as stated above, this dialog is triggered even if the LabVIEW installer was cancelled and wrote no files.
      Now, the above linked documentation refers to a flag I can put in my installer script to ignore this restart dialog, but it's a global flag, and I would like my other installers to still make use of this handy restart dialog if necessary. Unfortunately it seems LabVIEW installers trigger this even if not actually necessary.
      Has anyone seen this before? Any ideas how to make my LabVIEW installer NOT muck around with the MoveFileEx or wininit.ini stuff if/when it's not actually needed?  Attached is a LabVIEW project and Inno Installer script which easily reproduces the problem.  To reproduce:
      Extract the attached .zip Open test.iss in Inno Setup and click the "Run" button Alternately, just run the built installer under "\Output\test_inno_installer_9.99.0.0.exe" Click Next on 'Select Components' dialog Click Install on 'Ready to Install' dialog When LabVIEW installer pops up click Cancel, then yes (you're sure) See the Restart dialog Thanks!
      David_L
      InnoLabVIEWBug.zip
    • By DARTHWOD
      Hi Friends,
      I am facing issue in labview programming. My vi read csv file in a folder and plot it in waveform graph. Initially i have twenty csv file in that folder, while runnning my vi some more csv files will be added to that folder. The problem is only twenty csv file initially placed got read, later added csv files were not read by labview. 
      Condition: Once my vi starts running, the files will be automatically added to that folder. Because i am running an experiment which stores data in the form of csv file to that folder. How to keep on read the csv files continuosly while my experiments stores series of csv files.

    • By Dawid
      I'm trying to execute LPR.exe command to print some labels on a printer. However as its normal, problems occur. I could not find answer on any topic conneced with "sytem exec". I already tried all described methods (I think so). That's why I'm asking very kindly for any help.
      When trying to execute or call the LPR.exe from System exec VI, I'm receiving error:
      "'C:\Windows\System32\lpr.exe' is not recognized as an internal or external command, operable program or batch file."
      Generally I would like to call function: "lpr -S 192.168.1.5 -P lp C:\test\do_druku.txt" which works from command window without any problem.
       

      print.vi

    • By ATE-ENGE
      Background:
      I've been using LabVIEW for a few years for automation testing tasks and until recently have been saving my data to "[DescriptorA]\[DescriptorB]\[test_info].csv" files. A few months ago, a friend turned me on to the concept of relational databases, I've been really impressed by their response times and am reworking my code and following the examples with the Database Connectivity Toolkit (DCT) to use "[test_info].mdb" with my provider being a Microsoft jet oldb database.
      However, I'm beginning to see the limitations of the DCT namely:
      No support for auto-incrementing primary keys No support for foreign keys Difficult to program stored procedures and I'm sure a few more that I don't know yet.
      Now I've switched over to architecting my database in MySQL Workbench. Suffice to say I'm a bit out of my depth and have a few questions that I haven't seen covered in tutorials
       Questions (General):
       Using Microsoft jet oldb I made a connection string "Data Source= C:\[Database]\[databasename.mdb]" in a .UDL file. However, the examples I've seen for connecting to MySQL databases use IP addresses and ports.
      Is a MySQL database still a file? If not, how do I put it on my networked server \\[servername\Database\[file]? If so, what file extensions exist for databases and what is the implication of each extension? I know of .mdb, but are there others I could/should be using (such as .csv's vs .txt's)  My peers, who have more work experience than me but no experience with databases, espouse a 2GB limit on all files (I believe from the era of FAT16 disks). My current oldb database is about 200mB in size so 2GB will likely never happen, but I'm curious:
      Do file size limits still apply to database files? If so, how does one have the giant databases that support major websites?  Questions (LabVIEW Specific):
      I can install my [MainTestingVi.exe], which accesses the jet oldb database, on a Windows 10 computer that is fresh out of the box. When I switch over to having a MySQL database, are there any additional tools that I'll need to install as well? 
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.