in reply to Email Multiple Files from Same Directory

Looking in the Mail::Sender documentation, I see for the MailFile entry:

The file parameter may be a "filename", a "list, of, file, names" or a \@list_of_file_names.

I wonder what problem you encountered with that or how you would phrase it differently to make it more clear how to pass multiple files to the subroutine.

Replies are listed 'Best First'.
Re^2: Email Multiple Files from Same Directory
by BioLion (Curate) on Jul 20, 2009 at 15:18 UTC

    Failing that, OP could always Tar the files together and just mail that. Might also help if the files are large/numerous?

    Just a something something...
Re^2: Email Multiple Files from Same Directory
by cocl04 (Sexton) on Jul 20, 2009 at 19:09 UTC

    I can't figure out the syntax for the \@list_of_file_names. I have tried multiple ways. I have tried it with commas and without. I have tried with full directory and with just the file name. Any ideas?

      my @list_of_file_names = ('file1.txt','another_file.doc','/and/this/fi +le.pdf'); $sender->MailFile( { ... file => \@list_of_file_names, }

      or, alternatively

      ... $sender->MailFile({ ... file => ['file1.txt','another_file.doc','/and/this/file.pdf'], })

        I figured it out....The problem is fixed! Thanks All