TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Anurag Malani
NA
80
34.4k
The ':' character, hexadecimal value 0x3A, cannot be include
Dec 5 2013 2:31 AM
I have a problems after try execute: 1. System.Xml.XmlException: The ':' character, hexadecimal value 0x3A, cannot be included in a name
Please some one help me
My code is:
XDocument document = new XDocument(
new XDeclaration("1.0", "utf-8", "yes"),
new XElement("rss", new XAttribute(XNamespace.Xmlns + "media", "http://m.xyz.com/rss/"), new XAttribute("version", "2.0"),
new XElement("channel",
new XAttribute("vendor", "ABC"),
new XAttribute("lastpublishdate", DateTime.Now.ToString("dd/MM/yyyy hh:mm"))),
new XElement("title", "Videos"),
new XElement("media:thumbnail", new XAttribute("width", x.width.ToString().Trim()), new XAttribute("height", x.height.ToString().Trim())),
)
);
My Expected O/P-
<rss
xmlns:media
="
http://m.
xyz
.com/rss/
"
version
="
2.0
"
>
<channel
vendor
="ABC
"
lastpublishdate
="
05/12/2013 01:02
"
/>
<title>
Videos
</title>
<media:thumbnail
width
="
180
"
height
="
75
"
/>
</rss>
Reply
Answers (
1
)
Assign linq results to public list
How to check result set empty or null in linq????