InfopathForm datasource filters out newline

A

aalongsmile

I retrieve a share point list in a infopath form as follows

DataSource dmt = this.DataSources[dataSourceName];
XPathNavigator xDmtRoot = dmt.CreateNavigator();

string xPath =
string.Format(@"/dfs:myFields/dfs:dataFields//dfs:{0}[{1}]", nodeName,
condition);
XPathNodeIterator nodes= xDmtRoot.Select(xPath,
this.NamespaceManager);

string s = nodes.Current.GetAttribute("Body", "");

When I read the column "Body" which contains a text with newlines, the
newlines are filtered out, though the newlines in the share point list are
still present.

Any thoughts what I do wrong? I guess it should be not a problem to retrieve
a whole text with the common special characters.

Thanks for you help
Hans
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top