Can you view the actual characters - char by char - in the debugger probably the best way I can think of Are there control characters hidden in the strings (eg CR + LF in str1 & CR in str2) you could shove them into a byte array and check (code wise) byte be byte are they the same type of strings WideChars vs chars etc.
HTH Regards Paul McKenzie Analyst Programmer SMSS ltd. ----- Original Message ----- From: "James Low" <[EMAIL PROTECTED]> To: "Multiple recipients of list delphi" <[EMAIL PROTECTED]> Sent: Wednesday, November 13, 2002 3:35 PM Subject: [DUG]: String equivalence? > I have a chunk of code protected with the assertion: > assert(str1 = str2) ... (str1, str2 are String). > These strings are derived by walking an object hierarchy and are pretty big > (each 500 odd words according to word). > > Problem is, visually they appear identical, word thinks they are identical > (using compare documents ... ) but the assertion asserts they are not. > > If anyone know how I can work out what the difference between the strings > actually is, and thus how I can efficiently solve this problem (the objects > were cloned before deriving the strings ... they should be identical). > > This is D5. > > Thanks > > > James > Notice of Legal Status and Confidential Information: This electronic mail > message and any accompanying attachments may contain information that is > privileged and CONFIDENTIAL. If you are not the intended recipient you are > advised that any use, review, dissemination, distribution or reproduction of > the information is strictly prohibited and may be unlawful. If you have > received this document in error, please notify the sender immediately and > destroy the message. > -------------------------------------------------------------------------- - > New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED] > Website: http://www.delphi.org.nz > To UnSub, send email to: [EMAIL PROTECTED] > with body of "unsubscribe delphi" > Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/ --------------------------------------------------------------------------- New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED] Website: http://www.delphi.org.nz To UnSub, send email to: [EMAIL PROTECTED] with body of "unsubscribe delphi" Web Archive at: http://www.mail-archive.com/delphi%40delphi.org.nz/