开发者

How to trim whitespace from a data-bound XML element in WPF using XPath?

How can the whitespace at the start and end of the content of an 开发者_StackOverflowXML element be removed when binding to the element using XPath in WPF?


Assuming you mean something like:

<x:XData>
   <foo>     Bar    </foo>
</x:Data>

then there's no whitespace to trim here. Whitespace immediately following the opening tag, and immediately preceding the closing tag, is insignificant, and will be ignored anyway.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜