[prev in list] [next in list] [prev in thread] [next in thread]
List: perl-win32-users
Subject: RE: Pacify user.
From: "Messenger, Mark" <MMessenger () DIRECTV ! com>
Date: 2003-11-25 23:51:01
[Download RAW message or body]
Nope. Notice I was only replacing up to the "." . The remaining code on that line ( if ($linecount =~ /00$/); ) will ensure that the print statement only happens every 100 lines. :)
-----Original Message-----
From: Ted Schuerzinger [mailto:fedya@bestweb.net]
Sent: Tuesday, November 25, 2003 4:33 PM
To: perl-win32-users@listserv.ActiveState.com
Subject: RE: Pacify user.
Messenger, Mark graced perl with these words of wisdom:
> You could change
>
> print "."
>
> to
>
> print "($linecount/100)\r"
>
> perhaps?
Wouldn't printing a line to the console every time a line of the log file
was parsed add a fair amount of time to how long it takes to parse the
file?
Perhaps going through the file once doing nothing but counting the number
of lines, and then using that total to let the user know what percent of
the file was parsed might be a way to do it.
To be honest, though, I prefer the OP's solution of a 2x4 to the user's
head. :-)
--
Ted Schuerzinger
When will I learn? The answers to life's problems aren't at the bottom of
a bottle. They're on TV! --Homer Simpson
<http://www.snpp.com/episodes/7G04.html>
_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic