Ken, Call the code below with before and after versions of the file. The browse should come up with the first mismatch. Let us know what you learn - Joe
* Compare two files byte by byte PARAMETERS m.fn1, m.fn2 CLOSE all m.str1 = FILETOSTR(m.fn1) m.str2 = FILETOSTR(m.fn2) CREATE CURSOR COMP(C1 C(1), V1 N(3, 0), C2 C(1), V2 N(3, 0)) FOR m.x = 1 TO min(LEN(m.str1), len(m.str2)) m.C1 = SUBSTR(m.str1, m.x, 1) m.V1 = ASC(m.C1) m.C2 = SUBSTR(m.str2, m.x, 1) m.V2 = ASC(m.C2) INSERT INTO COMP FROM memvar ENDFOR * Find the first mismatch GO TOP LOCATE FOR C1 <> C2 BROWSE On Friday, April 10, 2009 2:00 PM, Kenneth Kixmoeller wrote: > >Date: Fri, 10 Apr 2009 13:00:16 -0500 >From: Kenneth Kixmoeller >To: [email protected] >cc: >Subject: Line-Enders, Brain-Benders > >Hey - - -- - -- -- -- > >I'm confused. (Before anyone else: "So what's new?") > >I am writing text to an Adobe proprietary format, called a tagged- >text file. Don't worry about that, not too important to the story, >but for the curious, is an ASCII file; the format is a sorta-hybrid >among XML, plain ol' ASCII, HTML, and WordStar <g>. > >The issue is this: In a PHP program that creates these files, I >append a CHR(13) to the end of each paragraph. Works swell, merges >into Adobe files like magic. I have another such function in a VFP >program (9 SP-whatever-the-latest-one-is). I do the same thing -- >adding the CHR(13) -- to each paragraph. Adobe products don't >recognize it as being anything but a vanilla ASCII file, and all of >the 'tags' are ignored. Part of the Adobe file format defines it as a >Windows-coded ASCII file. > >If, however, I open the file in VFP (just with a modi file), make a >trivial change (like: add a space, delete it again) and Save it, >Adobe recognizes it(!). > >I think it has something to do with line endings, but I can't see any >difference. > >My actual technique in the VFP program is to do a #DEFINE CRLF CHR >(13). I started with CHR(13)+CHR(10) but it didn't work, either. I >have tried putting the CHR(13) or CHR(13)+CHR(10) in there without >the defined CRLF. > >Question: I need to look at these files at the most intimate level to >figure out what the differences are. Tools? Ideas? > >Thanks, > >Ken > [excessive quoting removed by server] _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech Searchable Archive: http://leafe.com/archives/search/profox This message: http://leafe.com/archives/byMID/profox/[email protected] ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

