Altova Mailing List Archives>Archive Index >microsoft.public.xml Archive Home >Recent entries >Thread Prev - Re: How to read \r\n in MSXML? >Thread Next - Re: How to read \r\n in MSXML? Re: How to read \r\n in MSXML?To: NULL Date: 3/10/2008 9:36:00 AM "Joe Fawcett" <joefawcett@n...> wrote in message news:O50rTPogIHA.4684@T...... > "Adam Badura" <adam@h...> wrote in message > news:E6D1E2C8-16B0-4637-90AC-C9C18979EA85@m...... >> I have pretty formatted XML file like for example >> >> <root> >> <element></element> >> <element>spaces end spaces</element> >> <element>new line >> end new line</element> >> </root> >> >> The new lines are written (by MSXML) as \r\n. But after reading them >> (again with MSXML, preserveWhiteSpaces is set to true) the new lines are >> changed to \n (all other white spaces are alright, even the number of new >> lines is correct, only the are marked with \n instead of \r\n). >> Is there a possibility to have the \r\n preserved? (I cannot just >> change all \n to \r\n since this would change those \n which where lone >> \n in the XML file as well.) >> >> Adam Badura > As far as I know not through the XML interfaces. Changing carriage returns > and new lines to just new line is part of the XML specification under the > normalizing space rules. > > -- > > Joe Fawcett (MVP - XML) > > http://joe.fawcett.name Do you know what the relevant standard is? I assume it is a RFC. It seems very strange that the standard be a single linefeed. I know that the standard for email is clearly that a carriage return and linefeed combination be used; lines ending in just a linefeed is very non-standard for email. | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
