LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

call dll in LabVIEW written in C (pointers)

Hello you all...

I have a doubt related will calling dll functions in LabVIEW. Perhaps is very simple, but it's the first time I try to do this...

I have a dll written in C++ (not by me).
I have to call a funtion which prototype is:

char GetConfiguration(char *pVar1, float *pVar2, float *pVar3)

I use a "call library funtion node" and select the function, Run in UI thread option (??), stdcall (WINAPI) (otherwise it crashes), and built the prototype as follows

char GetConfiguration(CStr pVar1, float *pVar2, float *pVar3);

Is this correct?

Appart from that, How can I get the values of Var1, Var2 and Var3? I just wire an indicator to the "call library function node" outputs and nothing happens...

Please, help me!!!

Thanks and Regards

(Spanish help will also be welcome...)
0 Kudos
Message 1 of 2
(2,246 Views)
Hola Esther;

So far everything looks ok. You just need to add constants at the inputs to allocate the memory. The only thing I am not sure is the string: you need to have an idea on how long it is.

Todo se ve muy bien hasta ahora. Tan solo te falta colocar constantes en las entradas para separar espacio en memoria. Lo unico que no estoy seguro es en el "string": tienes que tener una idea de cuan largo debe ser.

Enrique
www.vartortech.com
0 Kudos
Message 2 of 2
(2,237 Views)