>Two things to check:
>1. This marker is for Word 2003 documents. Were the documents created with that version of Word?
> Docs from different versions of word have different identifiers.
>2. Some software write file structure at the end of the file too.
> The identifier of the end of Word 2003 documents is:
>
>chr(244) + chr(57)+chr(178)+chr(113)
>
>there is a lot of chr(0) after this identifier but they don't interfere in the file.
>See if you are getting something after that.
I always assumed that Visual FoxPro was putting everything after the marker as the file itself. So, I grab everything from that marker up until the end and that gives the file. I will have to check for that now. Maybe it would be related to the file being somewhat corrupted in Word.
For now, I use the following to check for the marker of various Word files:
IF tcFile='doc'
lnLocation=AT(0hD0CF11E0A1B11AE1,lcFile)
IF lnLocation>0
lcVersion="Word 10 Office 2000 File"
ELSE
lnLocation=AT(0h1234567890FF,lcFile)
IF lnLocation>0
lcVersion="MS Word 6.0 File"
ELSE
lnLocation=AT(0h7FFE340A,lcFile)
IF lnLocation>0
lcVersion="MS Word File"
ENDIF
ENDIF
ENDIF
ENDIF