Help for this page

Select Code to Download


  1. or download this
    if ( -s $infile ) {
        my $parser = Text::CSV::Simple->new;
        my @data = $parser->read_file($infile);
    }
    
  2. or download this
    if ( -z $infile ) {
        unlink $infile or die "Can't unlink empty file '$infile': $!";
        next FILE;
    }
    
  3. or download this
    eval {
        my $parser = Text::CSV::Simple->new;
    ...
       # unexpected error!
       die $@;
    }