XML deserialization using c#

107 views Asked by At

I am having a problem about XML deserialization because of names of tags.

It's my XML (will be imported from the web each time program starts (of course, with different blablas and different count number))

<history xmlns:oslc_cm="blabla" oslc_cm:collref="blabla">
    <oslc_cm:totalCount>10</oslc_cm:totalCount>     
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
    <history rdf:resource="blabla"/>
</history>

I need the "blabla" parts. If the outer had a different name, I would be able to deserialize the file, but here I don't know what to do since history class has the list of history class in it. Any ideas?

EDIT
I know how to define classes to deserialize an XML file. I'm having a hard time about the name issue

0

There are 0 answers