Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / XML / March 2007

Tip: Looking for answers? Try searching our database.

Errror Help: character ' ', hexadecimal value 0x2 is illegal in xml documents

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
raj - 26 Mar 2007 16:24 GMT
what does this error mean?  how can i fix this?

thanks,

raj
Bjoern Hoehrmann - 26 Mar 2007 16:30 GMT
* raj wrote in microsoft.public.dotnet.xml:
>what does this error mean?  how can i fix this?

You have an octet 0x02 or perhaps a character reference  in the
document. This is not allowed in XML 1.0; the latter is allowed in XML
1.1 but your version of the .NET framework probably does not support
that, and most likely you have not declared this version either. In
other words, your document includes random binary data and is there-
fore not an XML document. You have to correct the document before you
can successfully parse it.
Signature

Björn Höhrmann · mailto:bjoern@hoehrmann.de · http://bjoern.hoehrmann.de
Weinh. Str. 22 · Telefon: +49(0)621/4309674 · http://www.bjoernsworld.de
68309 Mannheim · PGP Pub. KeyID: 0xA4357E78 · http://www.websitedev.de/

Martin Honnen - 27 Mar 2007 12:36 GMT
> what does this error mean?  how can i fix this?

The XML 1.0 specification does not allow that character in an XML 1.0
document at all. The only way to include it and have it successfully
parsed with the .NET framework is to use a character reference in the
form of , then with .NET framework 1.1 and XmlTextReader that
character reference is allowed, with .NET framework 2.0 and XmlReader
such a character reference is allowed only with XmlReaderSettings and
the CheckCharacters property set to false.
Note however that while .NET allows such character references with those
settings the XML 1.0 specification disallows them so even if the .NET
XML parser accepts your XML a different XML parser might reject it.

Signature

    Martin Honnen --- MVP XML
    http://JavaScript.FAQTs.com/


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.