LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

most revelant between *.exe or *.dll for external code

Hi,

 

I have a little question, what is the most revelant to execute external code from C, C++, MatLAB, etc ?

I think for C code we have two possibilities, call dll or cal executable. What is the adventage and/or drawback for each solution ?

 

Thanks for reading. Marc.

0 Kudos
Message 1 of 4
(2,373 Views)

I would definitely recommend a dll for most situations, since that's the purpose of a dll - to be called from another application.

 

Are you calling code written in C, etc. from LV or code written in LV from C, etc.?

Chris
Certified LabVIEW Architect
Certified TestStand Architect
0 Kudos
Message 2 of 4
(2,356 Views)

Actualy it's just a reflexion with my self. My question is about the integration of C or C++ or Visual C++ code.

What appening with this code if we have to stop the application ?

Does it create a new thread when you call a dll ?

 

Marc

0 Kudos
Message 3 of 4
(2,346 Views)

That depends on how you setup the CLFN.  You can either configure the CLFN to run in a unique thread, or you can configure it to run in the UI thread.  The decision should generally be based on whether the dll is thread safe or not.

Chris
Certified LabVIEW Architect
Certified TestStand Architect
0 Kudos
Message 4 of 4
(2,343 Views)