Work better if :
@files = ('abc.txt', 'demo.log'); 

and
 
  Message => "This is a test.\nFile List:\n\". @files ."\n" 

if @files is not interpreted, try to create a variable $mess (for example)
before to assign it to Message => $mess
 
Yves

-----Original Message-----
From: Cary Hung [mailto:[EMAIL PROTECTED]]
Sent: Monday, June 10, 2002 8:33 AM
To: '[EMAIL PROTECTED]'
Subject: problem on sending @array via sendmail


Hi all, 

I've trouble in sending an array via sendmail, my code: 


use Mail::Sendmail; 
sub mail_send 
{ 
 %mail = ( 
  To      => '[EMAIL PROTECTED]', 
  From    => '[EMAIL PROTECTED]', 
  subject => 'ACS acknowledgment', 
  Message => "This is a test.\nFile List:\n\@files\n" 
         ); 
 sendmail(%mail) or die $Mail::Sendmail::error; 
 print "OK. Log says:\n", $Mail::Sendmail::log; 
} 


#main 


@files = ['abc.txt', 'demo.log']; 
mail_send; 


After receiveing email, I find the message has: 


This is a test. 
File List: 
@files 


(instead of 'abc.txt' and 'demo.log') 


Any help? 


Regard 
Cary 

_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to