This is a pain for me to deal with, maybe its my method or the way I'm
reading the file, but when I open a file, it reads only every 4th line.  The
way I thought it was set up, it should only read one line at a time.  Please
look at the code below and help me out if you can.

I've tried it several ways, and this one happens to be the last one I tried.
Any help would be useful.

( my(@allFiles) = readdir(DIRHND) ) || ( LogEntry(statslog, "Couldn\'t read
$userpts: $!") ); 
foreach $file (@allFiles) {
        my($sBody);  my($a);
        $file = "$userpts\\$file";
        print "$file\n";
        next unless ( open(FIL, "$file"));  ## I watched the code execute
and this statement actually gets the first line.
        $sRecp = <FIL>;                         ## whereas this one gets the
second line.
        while (<FIL>) {                         ## this one the third
                $sBody .= <FIL>;                        ## this one the
fourth
        }
        print $sBody;
        chomp($sRecp);
        close(FIL);
}
closedir(DIRHND);

Thanks
-jr


**********************************************************************
This email and any files transmitted with it are confidential
and intended solely for the individual or entity to 
whom they are addressed.  If you have received this email 
in error destroy it immediately.
**********************************************************************
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
http://listserv.ActiveState.com/mailman/listinfo/perl-win32-admin

Reply via email to