Hi Charles,

Thank you, It works now, I didn't post all the code as it was too long
and those other bits worked.

  if( unlink( $srcFile ) ){
    $comment = "Successful!!";
    $debug->printlog("Process $pid: DELETION " . &basename($srcFile) .
"\n$comment"); 
  }
  else{
    $errorComment = "ERROR: " . &basename($srcFile) . " deletion
failed:\n";
    $debug->printlog("$errorComment");
    &abort(1, "$errorComment");  
  }

Regards
Colin

-----Original Message-----
From: Charles K. Clarkson [mailto:[EMAIL PROTECTED] 
Sent: Monday, November 15, 2004 2:28 PM
To: [EMAIL PROTECTED]
Subject: RE: Unlink ? [edited]


Johnstone, Colin <[EMAIL PROTECTED]> wrote:

    Please send replies to the list.

: Hi Charles,
: 
: Thank you, I tried this instead.
: 
: my $cmdResult;
:
: if ( unlink( $srcFile ) ){
:     $cmdResult = 'Successful!';
:     $comment   = "DELETION: $cmdResult";
:     $debug->printlog( "DELETION $pid: Regen " .
:                       &basename($srcFile) . "\n$comment");
:
: } else {
:     $cmdResult = "Failed!" ;
:     $errorComment = "ERROR: " . &basename($srcFile) .
:                       " deletion $cmdResult\n";
:     $debug->printlog("$errorComment");
:     &abort(1, "$errorComment");
: }
: 
: It doesn't move to the next file in the array nor does
: it print the debug info to the log. 

    There is loop or array in the code above. Nor do we
know how you opened the log. Show more code. All of it
if its not too long.


HTH,

Charles K. Clarkson
-- 
Mobile Homes Specialist
254 968-8328


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




This E-Mail is intended only for the addressee. Its use is limited to that
intended by the author at the time and it is not to be distributed without the
author's consent. Unless otherwise stated, the State of Queensland accepts no
liability for the contents of this E-Mail except where subsequently confirmed in
writing. The opinions expressed in this E-Mail are those of the author and do
not necessarily represent the views of the State of Queensland. This E-Mail is
confidential and may be subject to a claim of legal privilege.

If you have received this E-Mail in error, please notify the author and delete 
this message immediately.


--
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