List Info

Thread: what does system() do?




what does system() do?
country flaguser name
United States
2007-02-08 12:33:19
Can any1 please explain the statement given below:

system ("SendToLogs.pl -msg  "Check
ServerConnection checked ok." -
appname checkServerConnection -level 2 " );

what is the system function trying to do here????

Thanx a lot!




Unsubscribing info is here: h
ttp://help.yahoo.com/help/us/groups/groups-32.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://g
roups.yahoo.com/group/perl-beginner/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http
://groups.yahoo.com/group/perl-beginner/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:perl-beginner-digest@yahoogroups.com 
    mailto:perl-beginner-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
    perl-beginner-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.c
om/info/terms/
 

Re: what does system() do?
country flaguser name
United States
2007-02-08 13:38:52
It is spawning a child process to run the SendToLogs.pl
script with a  
set of arguments.

It will wait until the script completes before continuing
execution.

It would be as if you had typed

% SendToLogs.pl -msg "Check ServerConnection checked
ok." -appname  
checkServerConnection -level 2

at the command line.

I can't tell you what SendToLogs.pl does; for that you'd
need to read  
it.

John Francini


On 8 Feb 2007, at 13:33, akhila_3 wrote:

> Can any1 please explain the statement given below:
>
> system ("SendToLogs.pl -msg "Check
ServerConnection checked ok." -
> appname checkServerConnection -level 2 " );
>
> what is the system function trying to do here????
>
> Thanx a lot!
>
>
> 



[Non-text portions of this message have been removed]



Unsubscribing info is here: h
ttp://help.yahoo.com/help/us/groups/groups-32.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://g
roups.yahoo.com/group/perl-beginner/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http
://groups.yahoo.com/group/perl-beginner/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:perl-beginner-digest@yahoogroups.com 
    mailto:perl-beginner-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
    perl-beginner-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.c
om/info/terms/
 

Re: what does system() do?
country flaguser name
United States
2007-02-08 15:45:09
At 01:38 PM 2/8/2007, you wrote:
>It is spawning a child process to run the SendToLogs.pl
script with a
>set of arguments.
>
>It will wait until the script completes before
continuing execution.
>
>It would be as if you had typed
>
>% SendToLogs.pl -msg "Check ServerConnection
checked ok." -appname
>checkServerConnection -level 2
>
>at the command line.
>
>I can't tell you what SendToLogs.pl does; for that you'd
need to read
>it.
>
>John Francini

And it returns the completion code back to the caller.. If
you want
the output of the command (e.g. date), I use the back tick
as in below:

$cur_date = `date`;

flk k



Unsubscribing info is here: h
ttp://help.yahoo.com/help/us/groups/groups-32.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://g
roups.yahoo.com/group/perl-beginner/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http
://groups.yahoo.com/group/perl-beginner/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:perl-beginner-digest@yahoogroups.com 
    mailto:perl-beginner-fullfeatured@yahoogroups.com

<*> To unsubscribe from this group, send an email to:
    perl-beginner-unsubscribe@yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.c
om/info/terms/
 

[1-3]

about | contact  Other archives ( Real Estate discussion Medical topics )