troubleshooting Question

Using XML in DataGrid - ASP.Net 2.0 using VB.Net

Avatar of brian2k1
brian2k1 asked on
.NET ProgrammingASP.NETVisual Basic.NET
9 Comments1 Solution4858 ViewsLast Modified:
I need some help getting an ASP.net 2.0 (VB) dataGrid working with an xml file.

The XML FIle is:
<gallery>
  <setup path="Gallery/Irrigation/">
    <imgWidth>470</imgWidth>
    <imgHeight>300</imgHeight>
    <thumbWidth>50</thumbWidth>
    <thumbHeight>40</thumbHeight>
    <transitionType>fade</transitionType>
    <thumbnailRows>1</thumbnailRows>
    <thumbPosition>bottom</thumbPosition>
    <captionPosition>top</captionPosition>
    <showControls>false</showControls>
    <backgroundColor>#FFFFFF</backgroundColor>
    <thumbActiveColor>#3B702A</thumbActiveColor>
    <thumbRollColor>#3B702A</thumbRollColor>
    <scaleToFit>true</scaleToFit>
    <soundThumbRoll></soundThumbRoll>
    <soundThumbClick></soundThumbClick>
    <captionPosition>bottom</captionPosition>
    <autoPlay>5</autoPlay>
    <transitionType>iris</transitionType>
    <stopAutoOnClick>false</stopAutoOnClick>
  </setup>
  <item>
    <thumb>AA002323.JPG</thumb>
    <img>AA002323.JPG</img>
  </item>
  <item>
    <thumb>AA002325.JPG</thumb>
    <img>AA002325.JPG</img>
  </item>
</gallery>

in the Page_Load
        Dim myDataSet As New DataSet()

        myDataSet.ReadXml(Server.MapPath("Gallery.xml"))

        dgBooks.DataSource = myDataSet
        dgBooks.DataBind()

in aspx
<asp:datagrid id="dgBooks" runat="server" />

I need to display each of the images /gallery/item/img

the problem seems to be the setup section is confusing the datagrid and it skips the item nodes.

I need to show each img from the item nodes, which I will eventually make a delete button/link for a quick image management tool.
ASKER CERTIFIED SOLUTION
arif_eqbal

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 9 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 9 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros