LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Executable's behaviour different from source code

I made a small program using Producer/Consumer structure. This program is used to acquire an analog signal with a PCI-6236 and display it.
The whole program works as long as it says under source code. As soon as I transform it onto executable, the behaviour is wrong :
  • one of the splash screen logo is changed (??)
  • it looks like orders are queued even if no event occured
This strange behaviour occurs on my development machine and also on host machines (in that case, the software program is installed using an installer w/ RTE & Daqmx included).

The main particularities of my program is to use a splash screen to launch the main VI. And I need DAQmx drivers in order to control the acquisition card.

Does somebody heard about that bug? Does anyone have a solution?

Thanks.

PS : sorry for my poor english
CLA, CTA, LV Champion
View Cyril Gambini's profile on LinkedIn
This post is made under CC BY 4.0 DEED licensing
0 Kudos
Message 1 of 8
(3,030 Views)

hi there

we need code!

 

Best regards
chris

CL(A)Dly bending G-Force with LabVIEW

famous last words: "oh my god, it is full of stars!"
Message 2 of 8
(3,020 Views)
The first place I would look is if the code uses relative paths.  The location where the executable is installed is obviously not where the source code resides, so if you have relative paths, then what would be relative to the executable's path?   Your description of the splash screen seems to be a clue to the problem..
Message 3 of 8
(3,015 Views)
The source code is attched to this post.
CLA, CTA, LV Champion
View Cyril Gambini's profile on LinkedIn
This post is made under CC BY 4.0 DEED licensing
0 Kudos
Message 4 of 8
(3,010 Views)

Thanks Altenbach!  This is what I suspect.. 

I am curious, with LV8.x (8.2 &up), is this still a problem when you use a project to build an executable?

The reason for asking is the link says it applies to LV8.2... 

Primary Software: LabVIEW Development Systems>>Full Development System
Primary Software Version: 8.2

I had learned my lesson with this issue in LV7.0 / 7.1.  Since then, I use a config file to store full path names and I stay away from "This path" or using relative path. 

A nice learning exercise is to have an indicator show the relative path when using the source code and then building an executable and seeing the difference in path..  😉

I did it in LV7.x. Maybe I should repeat the experiment.  Nevertheless, if you look at the context help info, it warns you about using "Current Path" when building an executable..  See attached image.

Message Edited by JoeLabView on 09-12-2007 07:32 AM

0 Kudos
Message 6 of 8
(2,960 Views)

Hi zyl7,

If you look at you splash screen code, you're using the Current Path vi that I mentionned in my last post.

By the way.. very nice code.  nice & clean, easy to read.  I like it 🙂

I just noticed something after posting the image..

The error cluster wire after the Flat Sequence Structure is not wired to the property node.

Also check out "Presse.vi".  Try not to hide the Queue reference wire (consumer loop) behind the Case Structure. 

 

Message Edited by JoeLabView on 09-12-2007 07:46 AM

Message 7 of 8
(2,956 Views)
Thanks for your answers. Neverthless I know that you must use "Current VI's path" carefully when you want to access files which are nor part of your application. If you look at my code, I only use "Current VI's path" to access other VIs. So even if the name of the executable is added to the path when the programs runs as an excutable, it shouldn't produce any bug.

C:\first.vi ->Current VI's path->Strip->Build->C:\second.vi
or
C:\myexe\first.vi ->Current VI's path->Strip->Build->C:\myexe\second.vi

It only makes changes when you do that :
C:\first.vi ->Current VI's path->Strip->Build->C:\file.txt
or
C:\myexe\first.vi ->Current VI's path->Strip->Build->C:\myexe\file.txt

Big difference!!

Do you have any other idea on what have produced the bugs listed in my previous message?

CLA, CTA, LV Champion
View Cyril Gambini's profile on LinkedIn
This post is made under CC BY 4.0 DEED licensing
0 Kudos
Message 8 of 8
(2,938 Views)