LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

system exec function

could someone give me a hint as to what the 'expected output size'
input on System Exec refers to? I'm using it to run another program
which will download some data for me to work on with labview. I dont
expect it has anything to do with the file size of that data?

Also, is there a way I can tell when the program I have called has run
to completion? Or can i just use the 'run to completion' boolean to
prevent the next part of the VI executing before the data has finished
downloading?

Thanks, Paul.S
0 Kudos
Message 1 of 4
(3,045 Views)
"mechatron" wrote in message
news:abb951a5.0212022147.7f0f550a@posting.google.com...
> could someone give me a hint as to what the 'expected output size'
> input on System Exec refers to? I'm using it to run another program
> which will download some data for me to work on with labview. I dont
> expect it has anything to do with the file size of that data?
A called program might pass some information, but when the application
terminates, the memory with this information is released. So, the program
passes a pointer to a string, but the memory it points to is removed.

To prevent this, the caller passes a pointer to a buffer, and the program
fills this buffer. Then it passes the same pointer back, and the caller can
read the message in it's
own memory. This buffer needs to be large enough.

If the program don't pass anything (you don't expect anything), just put the
"expected output size" on the default value. A buffer that is to big can't
do any harm.

> Also, is there a way I can tell when the program I have called has run
> to completion? Or can i just use the 'run to completion' boolean to
> prevent the next part of the VI executing before the data has finished
> downloading?
Yes, that's what is it for.


> Thanks, Paul.S
0 Kudos
Message 2 of 4
(3,045 Views)
Thanks Wiebe, appreciate your help. Might not need system exec if i
can figure out how to use the built-in dde server from the application
i want data from - Innotech GenesisII - documentation weak, cant find
much on NI - any pointers?

Regards, Paul.S
0 Kudos
Message 3 of 4
(3,045 Views)
Paul,

If you can use them both, the system exec will be simpler.

There used to be an example about DDE, interfacing with Excel. I suppose the
DDE technique is considered "obsolete"... The example is now using ActiveX.
The documentation for the DDE Vi's still are in the context help. The Vi's
are not in my pallete anymore.

Search for a library called ddeexamp.llb (probably in "program
files\national instruments\labview 6\ examples\comm"). This has a dde
example, for setting up a dde client / server system. I have no idea how to
do this for a Innotech GenesisII.

Regards,

Wiebe.

"mechatron" wrote in message
news:abb951a5.0212031756.1da87afe@posting.google.com...
> Thanks Wiebe, appreciate your help. Might not need syst
em exec if i
> can figure out how to use the built-in dde server from the application
> i want data from - Innotech GenesisII - documentation weak, cant find
> much on NI - any pointers?
>
> Regards, Paul.S
0 Kudos
Message 4 of 4
(3,045 Views)