I'm trying to load a xml (from a webservice) into a dataset. My issue is the xml doesnt always has the same structure.
it look like this
<Articles>
<Article>
<id>7156</id>
<name>FirstArticle</name>
<pic>zaea.jpg </pic>
</Article>
<Article>
<id>7157</id>
<name>Second</name>
</Article>
<Articles>
As you see first node has a "pic" the seconde hasnt. My problem is it will only load the first node into the dataset because "it has all property". If a node is missing one property it wont load it into dataset...
Here's what I do
Dim dataSet As New DataSet()
Dim httpResponse As String
httpResponse = HttpRequest.WRequest("WEBSERVICE URL")
Dim xmlSR As System.IO.StringReader = New System.IO.StringReader(httpResponse)
dataSet.ReadXml(xmlSR)
I allready try to add the column of the dataset before loading data but it doesnt change anything...
How can I do that? Thanx