String Literal Type

W

WJ

I've been going through an Xml Schema book and googling for a bit on this
and am having a hard time finding an answer.

I'm looking for a datatype for my xsd file that will hold a string literal.
The contents
will be XML, but I don't want it interpreted. The reason is this is for an
error handler.

So the XML will look something like:

<Error. . .>
<Data>
<ErrorMessage>You have bad elements</ErrorMessage>
<OriginalXml>
<XML1></XML1>
<XML2></XML2>
 
P

Priscilla Walmsley

Hi,

You could use a wildcard to indicate that any content is acceptable.
That is, the type for OriginalXML would look like:

<xs:complexType name="OriginalXMLType">
<xs:sequence>
<xs:any processContents="skip" namespace="##any" minOccurs="0"
maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>

Hope that helps,
Priscilla
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,997
Messages
2,570,240
Members
46,830
Latest member
HeleneMull

Latest Threads

Top