Using Linq to XML, is it possible to store " in an attribute?
Using Linq to XML, is it possible to store &q开发者_JS百科uot; in an attribute.
So if I look at the xml source, it will show "
What I've tried so far, is
new XAttribute("AttribName", "'")
But that just stores '
If I try
new XAttribute("AttribName", """)
Then it will store "
Your first version is an apostrophe, not a quotation mark. Try this:
new XAttribute("name", "\"");
精彩评论