Groups | Blog | Home
all groups > dotnet xml > november 2005 >

dotnet xml : Reading a specific set of elements from xsd



ricolee99 NO[at]SPAM hotmail.com
11/25/2005 9:14:04 AM
Hi there,

I have an xsd file:

<xsd:element name="RESULTS">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="SEARCH_CRITERIA"
type="OutputType:SomeType" minOccurs="0"/>
<xsd:element name="NAMES" minOccurs="0">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="NAME" minOccurs="0"

maxOccurs="unbounded"> <xsd:complexType> <xsd:sequence>
<xsd:element name="SOME_ID" type="OutputType:SomeType"/>
<xsd:element name="RECORD_CREATE_TMS"
type="OutputType:SomeType"/>


etc...


Under the element "Names" I'd like to iterate thru the sequence to
obtain the element names: "SOME_ID", "RECORD_CREATE_TMS" , etc.

Can someone please tell me how to do this in C#?

Thanks

Sharon
DC
11/30/2005 9:51:01 PM
huh?

what is it that you want to do?
do you want to parse an XSD ?
If so, have you tried the XmlReader?

and...?

help us out here.

-D



[quoted text, click to view]

Zafar Abbas
12/1/2005 10:02:51 AM
find the XmlSchemaComplexType object which represents the type of the
element. Under the type there should be a XmlSchemaSequence object which
contains all elements as objects of XmlSchemaElement.

[quoted text, click to view]

AddThis Social Bookmark Button