LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

running from source versus executable

Solved!
Go to solution

Hi...  I have a reasonbly complex piece of LabVIEW code developed by a commercial company to run some hardware they sell...  In recent times I have successfully operated their hardware from an executable made from their source code...  So far so good...  That hardware will be available to me again soon but isn't today.  Wanting to start some code changes I need to make I wanted to see how hard it would be to get the source code to run even though there is no hardware attached...  (There's a lot of TCP/IP comm that normally goes on so I knew there would be a lot of "circumventing" of code to do...  That's true at source...  However, when I ran the executable made from the original source code, I don't get a single error... I don't actual data, of course, out either but I can fake that...  My curious question is why would a piece of source code that expectedly generates a ton of errors subsequently and quite unexpectedly generate NO ERRORS at all when run from an executable made directly from that source code...  I even went so far as to retest the source (tons of errors) and then right at that moment build a new executable just to be sure that I was correct that the executable was made directly from this specific source code...  The executable ran with no errors at all...  That's actually a very useful outcome for me but I don't understant why the executable generates no errors...  Your thoughts???  thanks.. bob...

0 Kudos
Message 1 of 5
(2,196 Views)

Are the errors being handled?

 

My first thought is that you have automatic error handling on in your development setup and the errors are not being propagated/being handled by code.  In the EXE, the automatic error handling is gone.  Therefore the errors just go into the ether.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 5
(2,193 Views)

Some of the errors are handled in the source code...  Some are not...  Just now I intentionally added the error handling I mentioned to the left...  Now to say "handled" all I did was wire an error indicator to the TCP/IP strings versus leaving those error outputs unwired as they were when I originally found them..  And I placed the indicators on the front panel so I could see them.  I then built another executable, ran it, and again it runs...  Errors certain show up in the three Error Indicators I just now created but that doesn't seem to impact the codes ability to go ahead and run (granted not generating real data of course but again, I can fake that for what I am trying to do).  There are other errors, however, that put up dialog when I run from source that I haven't touched in what I just did...  And as before, when I run from executable, not the errors that are handled with indicators nor errors that are not handled at all put up any kind of dialog (to stop me) when running from the executable...  So to answer your question, I would say (now at least), some are handled as I described above with ust error indicators and others are not handled at all...  But the executable "works" meaning it puts up no show stopping error dialogs at all... 

 

thoughts????

0 Kudos
Message 3 of 5
(2,182 Views)
Solution
Accepted by topic author paris1_

As I said before, you have automatic error handling turned on in your development environment, but it doesn't exist in the EXE.  Use a Simple Error Handler to "handle" your errors and you will get your annoying popups.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 4 of 5
(2,177 Views)

Yep, you were exactly correct...  thanks for the help...  bob...

0 Kudos
Message 5 of 5
(2,159 Views)