ramki067 has asked for the wisdom of the Perl Monks concerning the following question:
Please help. Regards, Ramkimy $ldir = "/Android"; $RESULTS_FILE = $ldir.'/'.'results.html'; open OUT, ">>", $RESULTS_FILE; open(IN,"<logcat.txt"); while(<IN>) { chomp; if( $_ =~ m/Unable to parse/ ) { my @string = split('/',$_); print @string; my $stream_name = $string[4]; while $srch(<OUT>) { chomp; if( $srch =~ m/$stream_name/ ) { // How to replace the line here? } } } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Open a file, search for a string and fill a string in another file
by davido (Cardinal) on Jan 23, 2014 at 08:20 UTC | |
|
Re: Open a file, search for a string and fill a string in another file
by McA (Priest) on Jan 23, 2014 at 08:10 UTC | |
by ramki067 (Acolyte) on Jan 23, 2014 at 09:11 UTC | |
|
Re: Open a file, search for a string and fill a string in another file
by kcott (Archbishop) on Jan 23, 2014 at 16:06 UTC |