Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Fatal XML Parse Error: Invalid character (Unicode: 0x1D)

From: Martin Honnen <mahotrash@-----.-->
To: NULL
Date: 11/6/2009 4:49:00 PM
Ismo Salonen wrote:
> JR wrote:
>> I apologize up front for not being much of an XML guy.  We are trying 
>> to use a canned solution to send barcode strings via XML.  The canned 
>> solution works fine.  The one issue we are having is that the barcodes 
>> are GS1 compliant meaning we have ASCII character 29 (0x1D) embedded 
>> in our barcodes.  We want these strings to contain the character, but 
>> the parser just doesn't like them.
>>
>> Our heading is as follows:
>> <?xml version="1.0" encoding="utf-8" ?>
>> Anyone know of a means of passing such characters in an XML string?
>>
> 
> Could you use [CDATA] for those parts which use special reserved chars ?

A control characterlike 0x1D is not a special reserved character, it is 
not an allowed character. CDATA sections help to make your data more 
readable as you can use
   <foo><![CDATA[a < b && b < c]]></foo>
instead of
   <foo>a &lt; b &amp;&amp; b &lt; c</foo>
but they don't help to put in characters that are not allowed in XML.


-- 

	Martin Honnen --- MVP XML
	http://msmvps.com/blogs/martin_honnen/


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent