Hello,
Can anyone show me how to define in an XSD schema that an element in an XML document can either contain no text, or if it does contain text that the text has to be of a specific type.
For example, I would like both the following to be valid, where any text present should equate to an integer, but an empty element is also valid:
<mytest></mytest>
or
<mytest>123</mytest>
Many thanks in advance
Can anyone show me how to define in an XSD schema that an element in an XML document can either contain no text, or if it does contain text that the text has to be of a specific type.
For example, I would like both the following to be valid, where any text present should equate to an integer, but an empty element is also valid:
<mytest></mytest>
or
<mytest>123</mytest>
Many thanks in advance