
Searching a WORD 6 DOC by line line number
On Tue, 18 Nov 1997 17:37:17 -0600, Michael Farris
Quote:
>I want to write a PERL script to read through a MS Word document and
>return a line number where a match occurs.
>The problem is the binary line breaks. How can I open the file into an
>array that can be read line by line. I've tried out splitting on \m and
>a few others but I'm not sure what WORD uses for its line breaks.
They say "a little knowledge is a dangerous thing", and I think they
are right.
Don't try and treat a Word document like a text file, because its not.
Save as text, then run through it, or look at the LAOLA docs for some
more info.
Mike