473,395 Members | 1,532 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

XmlReference to undeclared entity, 'LT'

Hi

Im trying to load a XmlDataDocument with the following xml:

<ROOT>
<NAME> &LT; &AMP; &GT; " '</NAME>
</ROOT>

And i know I have a entity problem here, but i cant find any solution for
it. The problem is that i recive this from external source and cant
influence the xml content. Please help!

Best regards
Tobbe

Nov 12 '05 #1
5 3499


tobbe wrote:

Im trying to load a XmlDataDocument with the following xml:

<ROOT>
<NAME> &LT; &AMP; &GT; " '</NAME>
</ROOT>

And i know I have a entity problem here, but i cant find any solution for
it. The problem is that i recive this from external source and cant
influence the xml content.


Well the entities defined are named amp, lt and gt and they need to be
referenced as &amp; &lt; and &gt; thus whoever sends you the source
needs to learn how to send XML and not something similar to XML.

--

Martin Honnen
http://JavaScript.FAQTs.com/

Nov 12 '05 #2
Hmmm the message is automatic sent back from Navision to a reply queue in
msmq. Dont know how much i can change there...

I found the method XmlDataDocument.CreateEntityReference() but i cant find
any articles descibling how to us it. Can this possibly help me!?

"Martin Honnen" <ma*******@yahoo.de> skrev i meddelandet
news:%2****************@TK2MSFTNGP11.phx.gbl...


tobbe wrote:

Im trying to load a XmlDataDocument with the following xml:

<ROOT>
<NAME> &LT; &AMP; &GT; " '</NAME>
</ROOT>

And i know I have a entity problem here, but i cant find any solution for it. The problem is that i recive this from external source and cant
influence the xml content.


Well the entities defined are named amp, lt and gt and they need to be
referenced as &amp; &lt; and &gt; thus whoever sends you the source
needs to learn how to send XML and not something similar to XML.

--

Martin Honnen
http://JavaScript.FAQTs.com/

Nov 12 '05 #3
tobbe wrote:
Hmmm the message is automatic sent back from Navision to a reply queue in
msmq. Dont know how much i can change there...
This is definitely a bug. That's just malformed XML.
I found the method XmlDataDocument.CreateEntityReference() but i cant find
any articles descibling how to us it. Can this possibly help me!?


You want to create more entity references? Why?
You problem is that &LT; entity reference isn't defined.
Can you just string replace &LT; to &lt; before parsing the XML?
--
Oleg Tkachenko [XML MVP]
http://blog.tkachenko.com
Nov 12 '05 #4
--> Can you just string replace &LT; to &lt; before parsing the XML

Sure i get the xml from MSMQ as a string, ill try that!
*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #5
Thanks Oleg it work perfectly!!!

*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Romeo Disca | last post by:
Hello newsgroup, i'm new to xml - what's wrong with this piece code here? i have these two files: test.xml ---- <?xml version="1.0" encoding="utf-8"?> <!DOCTYPE a SYSTEM "test.ent"
2
by: Ed Dennison | last post by:
I'm starting to look at DocBook-XML (not SGML) for producing a large documentation set. The hierarchy of DocBook elements for organizing the content is (more or less); set book part chapter...
5
by: Stephan Hoffmann | last post by:
Hi, I use XML mainly as a source for HTML. HTML browsers 'know' certain entity references like &eacute; or &auml;. When I use XSL to transform XML to HTML or XML, these entities are replaced...
0
by: Frederico Guimar??es via DotNetMonster.com | last post by:
Hi, I'm trying to use the Microsoft.Web.Services2.Messaging. ISoapFormatter but I receive this error: System.Xml.XmlException: Reference to undeclared parameter entity, 'meetingmaker'. at...
10
by: Jon Noring | last post by:
Out of curiosity, may a CDATA section appear within an attribute value with datatype CDATA? And if so, how about other attribute value datatypes which accept the XML markup characters? To me,...
9
by: Eric Lindsay | last post by:
I can't figure how to best display little snippets of shell script using <pre>. I just got around to organising to bulk validate some of my web pages, and one of the problems occurs with Bash...
1
by: five of nothing | last post by:
Hi, I'm working on a page and my HTML validator whines when I try to put a <div></div> or a <table></table> inside of an <a></a> tag. What are the rules as far as what can go in there?
232
by: robert maas, see http://tinyurl.com/uh3t | last post by:
I'm working on examples of programming in several languages, all (except PHP) running under CGI so that I can show both the source files and the actually running of the examples online. The first...
7
by: Andrew Robinson | last post by:
I have a method that needs to return either a Dictionary<k,vor a List<v> depending on input parameters and options to the method. 1. Is there any way to convert from a dictionary to a list...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.