Re: Problem in opening the file using Tail Module



sivasakthi wrote:

I have used the following code to print the log files. but nothing is
printed even it doesn't show the warning message, no prompt is returned. what is the mistake in code , could u help me to find the
pbm???

#!/usr/bin/perl
use strict;
use warnings;

use File::Tail;
my $file=File::Tail->new("/some/log/file/path"); while (defined(my $line=$file->read))
{
print "$line";
}

File::Tail will read only lines that are added to the file after it has been
opened. Your program will simply sleep until something new is added.

Rob
.



Relevant Pages

  • Re: TextBox Validating event firing twice
    ... My mistake. ... Dan ... > If something is wrong in user input I show a warning message. ... > displayed twice (event fired twice). ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Problem in opening the file using Tail Module
    ... Give a try to add '$|++' to disable IO buffer. ... printed even it doesn't show the warning message, ... what is the mistake in code, could u help me to find the pbm??? ... use strict; ...
    (perl.beginners)
  • Re: Problem in opening the file using Tail Module
    ... Give a try to add '$|++' to disable IO buffer. ... printed even it doesn't show the warning message, ... what is the mistake in code, could u help me to find the pbm??? ... use strict; ...
    (perl.beginners)
  • Re: File Download Prompt Check Box
    ... > I'm trying to find a way to re-establish the prompt box that allows me ... I unchecked this warning message and don't know how to ... Prev by Date: ...
    (microsoft.public.windowsxp.general)
  • Re: How to convert MSG files to PDF
    ... that tool doesn´t "eliminate" the prompt. ... called ClickYes Pro. ... This tool eliminates the warning message that pops ... up when I'm using the SaveAs method on the mail item. ...
    (microsoft.public.outlook.program_vba)