in reply to Retrieval of e-mail body

i have to agree with jeffa -- the  $#$body syntax ends up being really clunky.

i'd do something similar to what tadmans's already done:

my @body = @{ $message->Body }; # force array context foreach my $line ( @body ){ ## process to your heart's content }