Nishi Prafull wrote:
> Hi:
> Apparently I noticed that when I put both the commands I need to run
> in one script using the system call, the second command does not get
> executed ( I cannot figure out the cause).
        They would have to be two separate calls.  I used to start 10 to 15 
processes at one time using a Perl script to get my setup the way I wanted it.  
Then I knew exactly where they were and the order they were in.

        So you only need to do;

        my $MyStatus1 = system('script1.pl');   # make sure you qualify  the 
script as much as necessary and not rely on                                     
                           # paths.
        # should check that status was a success which i believe is backwards 
from what Perl defines as success(0: good, <>     # 0:error)

        my $MyStatus2 = system('script2.pl');   # second one to execute.

Wags ;)
> Each of the commands are making out calls to software installed on the
> machine to perform specific tasks.
> 
> Do I have to do anything else in this regard?
> 
> Thanks.
> 
> On Thu, 3 Mar 2005 15:50:16 -0800, Tim Johnson <[EMAIL PROTECTED]>
> wrote: 
>> 
>> I guess it partly depends on what you are trying to accomplish.  Why
>> are you calling a second script? 
>> 
>> 
>> -----Original Message-----
>> From: Nishi Prafull [mailto:[EMAIL PROTECTED]
>> Sent: Thursday, March 03, 2005 3:47 PM
>> To: beginners@perl.org
>> Subject: call a perl script within another perl script
>> 
>> Hi:
>> I would like to call a perl script(B.pl) within another perl
>> script(A.pl). Should I use the following approach or something else?



*******************************************************
This message contains information that is confidential
and proprietary to FedEx Freight or its affiliates.
It is intended only for the recipient named and for
the express purpose(s) described therein.
Any other use is prohibited.
*******************************************************


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to