in reply to Re: Reading entire file.
in thread Reading entire file.
I do have some sample text in my origional post. That is simular
to what can be found in my text file, except there are 26 of one type
of tool, 20 of another type, and 10 of another. I am only conserned
with the first 26. My actual code is:
the value for $tool_number is Tool01 which will and does give $end_tool a value of Tool02. Everything that I have checked up to this point seems to work except the loop. I tried some code that was posted as a reply to another question.
that did not seem to work either.
stuffy
while (<PD_FILE>){ if (/$tool_number/) $continue = 1; } if (/$end_tool/) $continue = 0; } if ($continue){ print $_; } }
the value for $tool_number is Tool01 which will and does give $end_tool a value of Tool02. Everything that I have checked up to this point seems to work except the loop. I tried some code that was posted as a reply to another question.
while (<^(*?)$tool_number(.*)$/) {
that did not seem to work either.
stuffy
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Reading entire file.
by cLive ;-) (Prior) on May 04, 2001 at 13:43 UTC | |
Re: Reading entire file.
by cLive ;-) (Prior) on May 04, 2001 at 13:28 UTC | |
by stuffy (Monk) on May 04, 2001 at 13:55 UTC |
In Section
Seekers of Perl Wisdom