LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to "compile" a vi ti run in Runtime-version?

Hello,
i have set of working VIs to control visa-instruments. I call these VIs in NI TestStand.

Is it possible to "compile" the VIs to generate something like a DLL?
Or what to i have to do that:
1.) No one can see my LV-code and
2.) Others don´t need a Labview-version to run the VIs (only the free runtime version should be used).

Thanks for your help
0 Kudos
Message 1 of 5
(2,824 Views)

Toc reate a standalone executable or a DLL from a VI, you need the application builder. It is included in LabVIEW professional and above. If you have LabVIEW base or full only, you can order it seperately.

See: http://www.ni.com/pdf/products/us/4msw55.pdf for details.

 

0 Kudos
Message 2 of 5
(2,822 Views)
I have LV professional 8.2
In the menue it is possible to create an EXE-file at "TOOLS + Built Executable".
How can i switch this to create a DLL?
0 Kudos
Message 3 of 5
(2,819 Views)
The trick is to create a new "Build-Specification".
Default is exe, then only right-click on "Build-Specifications" ad select "New + Shared Library (DLL)". Then a DLL is created.
Works now without problems.

One more question is:
When i create a function with "typical" types like string or numeric then TestStand says "This function has parameter information. Would you like to use it?". When i click "YES" the the parameters are automatically added in the teststand-steptype.

But when i add the default labview-errorcluster as an output and do the same then TestStand says: "this function does not have parameter information in the DLL or types not recogniced by Teststand."

Is there a trick that the error-output can be automatically added?
In the project-explorer in "Define Prototype" the function-call looks like this:

void SumTest(double NrA, double NrB, double *Sum, double *Mal, TD1 *errorOut)


0 Kudos
Message 4 of 5
(2,814 Views)
I found a header-file next to the dll with the information of the parameter "TD1". It look like this:
So where is the problem for TestStand?

Thanks for any hint.

*********************
#include "extcode.h"
#pragma pack(push)
#pragma pack(1)

#ifdef __cplusplus
extern "C" {
#endif
typedef struct {
    LVBoolean status;
    long code;
    LStrHandle source;
    } TD1;


void __stdcall SumTest(double NrA, double NrB, double *Sum, double *Mal,
    TD1 *errorOut);

long __cdecl LVDLLStatus(char *errStr, int errStrLen, void *module);

#ifdef __cplusplus
} // extern "C"
#endif

#pragma pack(pop)

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