LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

command line

Is it possible to build an LV application that accepts command line options?
I am using LV 5.1.

TIA,

Chris
0 Kudos
Message 1 of 7
(4,022 Views)
Go to http://zone.ni.com/devzone/devzone.nsf/webcategories/2E4161187E3DEB30862568660020BCC8?opendocument

Chris Cocozzo" wrote:
>Is it possible to build an LV application that accepts command line options?>I
am using LV 5.1.>>TIA,>>Chris>>
0 Kudos
Message 2 of 7
(4,022 Views)
I'm sure that what you want to accomplish is possible. Simple develop a
LabVIEW application that acts as a command server. What do you mean by
command line options? Are you running on a UNIX platform? Are you looking
to run UNIX commands from within a LabVIEW application?
-Tom
Chris Cocozzo wrote in message
news:UhR86.14$I6.54892@news-west.usenetserver.com...
> Is it possible to build an LV application that accepts command line
options?
> I am using LV 5.1.
>
> TIA,
>
> Chris
>
>
0 Kudos
Message 3 of 7
(4,022 Views)
First off, this is for the windows platform. I develope a lot of testing
type programs that need to run all of the time without user intervention. I
normally build a front menu where the user can configure or run the program.
What I want to do is be able to pass a command line option to the exe to
tell the program to automatically come up running. For example, make a link
to the exe in the Startup folder (something like "C:\Prog\Prog.exe 1") to
make it skip the menu.


Tom Byers wrote in message
news:t6co9m3uhj7hcb@corp.supernews.com...
> I'm sure that what you want to accomplish is possible. Simple develop a
> LabVIEW application that acts as a command server. What do you mean by
> command line options? Are you running on a UNIX
platform? Are you
looking
> to run UNIX commands from within a LabVIEW application?
> -Tom
> Chris Cocozzo wrote in message
> news:UhR86.14$I6.54892@news-west.usenetserver.com...
> > Is it possible to build an LV application that accepts command line
> options?
> > I am using LV 5.1.
> >
> > TIA,
> >
> > Chris
> >
> >
>
>
0 Kudos
Message 4 of 7
(4,022 Views)
Chris Cocozzo wrote:

> First off, this is for the windows platform. I develope a lot of testing
> type programs that need to run all of the time without user intervention. I
> normally build a front menu where the user can configure or run the program.
> What I want to do is be able to pass a command line option to the exe to
> tell the program to automatically come up running. For example, make a link
> to the exe in the Startup folder (something like "C:\Prog\Prog.exe 1") to
> make it skip the menu.

Go to zone.ni.com and search on command line
there are several ways to do this.
Kevin
0 Kudos
Message 5 of 7
(4,022 Views)
Drop a "Call Library Function" node and configure as following:

Library name: kernel32.dll
Function name : GetCommandLineA
Calling convention: stdcall
Return type: String, C String Pointer

The Function Prototype should display:

CStr GetCommandLineA(void);

Make this a VI that returns the output parameters.

The output will be want you want.

Jean-Pierre Drolet



"Chris Cocozzo" a écrit dans le message news:
WTw96.571$g7.266823@news-west.usenetserver.com...
> First off, this is for the windows platform. I develope a lot of testing
> type programs that need to run all of the time without user intervention.
I
> normally build a front menu where the user can configure or run the
program.
> What I want to do is be able to
pass a command line option to the exe to
> tell the program to automatically come up running. For example, make a
link
> to the exe in the Startup folder (something like "C:\Prog\Prog.exe 1") to
> make it skip the menu.
>
>
> Tom Byers wrote in message
> news:t6co9m3uhj7hcb@corp.supernews.com...
> > I'm sure that what you want to accomplish is possible. Simple develop a
> > LabVIEW application that acts as a command server. What do you mean by
> > command line options? Are you running on a UNIX platform? Are you
> looking
> > to run UNIX commands from within a LabVIEW application?
> > -Tom
> > Chris Cocozzo wrote in message
> > news:UhR86.14$I6.54892@news-west.usenetserver.com...
> > > Is it possible to build an LV application that accepts command line
> > options?
> > > I am using LV 5.1.
> > >
> > > TIA,
> > >
> > > Chris
> > >
> > >
> >
> >
>
>
0 Kudos
Message 6 of 7
(4,022 Views)
Chris,

This is possible, I've done this. If I recall correctly, the main problem is
that it only works with executables (the command line is "labview.exe
nameofvi.vi", i.s.o. "nameofvi.exe option"). I'll send them to you. We'll
also place the VI in our online library (www.air.nl) before 23 jan.

Regards,

Wiebe Walstra.

--
AIR technical Automation
www.air.nl
"Chris Cocozzo" wrote in message
news:UhR86.14$I6.54892@news-west.usenetserver.com...
Is it possible to build an LV application that accepts command line options?
I am using LV 5.1.

TIA,

Chris
0 Kudos
Message 7 of 7
(4,021 Views)