Newline in Xml text content (Excel)

  • Thread starter Thread starter Dag Johansen
  • Start date Start date
D

Dag Johansen

Hi all,

I want to generate an Excel spreadsheet as an xml file and
use
text on several lines in a cell.

This works:
<Data ss:Type="String">Line 1
Line 2</Data>

This does not work:
<Data ss:Type="String">Line 1
Line 2</Data>

Trouble is, the implementation of the XML DOM I'm using
(.Net System.Xml classes) will not render the first
representation, and loading the second one in Excel
ignores the newline character.

Is this an encoding problem?
Does anyone know of a work-around?

Many thanks to all who can provide input. Regards,

Dag Johansen
dagOystein . johansen @ sage . com
 
Hello Johansen
In Windows applications, a new line in the text is
normally stored as a pair of CR LF (carriage return, line
feed) characters.

is for new line LF which changes the line while
displaying data
Please Let me know if you don't satisfy with it
Regards,
Rahul Shukla
 
Back
Top