On Monday 17 May 2004 03:15, Sudhindra Bhat wrote: > > Hi Hello,
> I wanted some help on a piece of code that I was writing. Well the > requirement is like this. I have a file whose looks like this > > (1) Test: 123456 ABCDEF > > 123456 > > (2) Results: ABCDEF > > Now I want my script to output all the contents between the two tags > Test and Results. i.e. 123456 ABCDEF 123456. Can someone help me with > this? while ( <FILE> ) { if ( /Test:/ .. /Results:/ and !/Test:/ and !/Results:/ ) { print } } John -- use Perl; program fulfillment -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>