LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Is it possible to Pass Command line arguments to a LabVIEW DLL

Hi all,

I have requirement  where, I have to call a labview dll from command line and pass argument s to the  the dll.

I want to whehter  it is possible to call a labview dll  from command line and pass  arguments through command line.

 

Please share your views on this

Regards

Aju Samuel

0 Kudos
Message 1 of 4
(4,014 Views)

How are you calling the LabVIEW DLL from the command line? A DLL is just a library of code so it can't be called directly (unless there's something I'm missing? I thought you could only run executables from the command line?

 

It is possible to pass command line arguments to a LabVIEW Executable by ticking the 'pass all command line arguments to application' option in the build specification and you can then access them using the Application property Command Line Arguments which returns an array of arguments - there's some information on that here: https://decibel.ni.com/content/docs/DOC-10281


LabVIEW Champion, CLA, CLED, CTD
(blog)
Message 2 of 4
(4,005 Views)

Hi Sam,

Thanks  for the reply

I tried  calling Labview excutable from command line  and passing argument s through command line. It was succesful.

But  I have requirement where I have  ot call  labview dlls from  a third party software  which only supports  command line scripting.

 

I want  to make sure  whether it is  possible  to  call  LabviewDLL from command line . Other  wise  i have  go with the executables

 

Regards

Aju Samuel

 

 

 

 

0 Kudos
Message 3 of 4
(3,999 Views)

No, it is not possible. As I said, a DLL is a compiled library of functions - it cannot execute on it's own. You can call the functions in that DLL from any programming language by using the appropriate include/function calls (from the header file that gives you the function prototypes). This isn't just true for LabVIEW - it's the same for any other DLL.

 

You will need to either call the functions from the DLL in your other software, or write a LabVIEW executable which takes in the command-line arguments and runs the appropriate functions. This executable could even call the LabVIEW DLL you have produced!


LabVIEW Champion, CLA, CLED, CTD
(blog)
0 Kudos
Message 4 of 4
(3,992 Views)