Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Help with loading data in Grid

Posted on 2012-04-04
5
Medium Priority
?
395 Views
Last Modified: 2012-04-30
Hello, I created  the xml file below to try to load a grid with data in three rows in the following format


<Root>
  <xx>
    <xxID>1</xxID>
    <xx></xx>
  </xx>
<xx>
    <xxID>2</xxID>
    <xx></xx>
  </xx>
<xx>
    <xxID>3</xxID>
    <xx></xx>
  </xx>
</Root>

Desired Format in Grid:

xxID     xx
1
2
3

The goal is have users enter data in the xx column and save them to another xml file in the following format:

xxID     xx
1         1-Data1
2         2-data2
3         3-Data3

Save in following format:

1-Data; 2-Data2; 3-Data3

My problem is the Grid shows the data in a totally differnt format and I am unable to edit data in the xx column.

How do I fix this problem?

Below is the code use to load the xx.xml file

Dim xx As New DataSet
            xx.ReadXml(Server.MapPath("~/App_Data/xx.xml"))
            C1GridView1.DataSource = xx.Tables(0)
            C1GridView1.DataMember = "xx"
            C1GridView1.DataBind()

I am using a grid from ComponentOne but I thing this should also apply toa regular Gridview.

Victor
0
Comment
Question by:vcharles
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 83

Expert Comment

by:CodeCruiser
ID: 37805033
Have you set the grid to be edit able? And how is grid showing data? Screenshot.
0
 

Author Comment

by:vcharles
ID: 37805253
Hi,

I was able to edit data after I set the Grid to editable, but I don't know I am getting columns which don't match my xml file (xx-id, xx_id_0), I only want towo columns but I am getting three and it seemslike every two rows has an ID value. Also everytime I clicked on the cell to add data I received the error on slide 2 and I clicked on continue I was able to add the data.
screenshot.pptx
0
 

Author Comment

by:vcharles
ID: 37806329
Help!
0
 
LVL 83

Accepted Solution

by:
CodeCruiser earned 2000 total points
ID: 37807703
Trouble is you are using a 3rd party control so its very difficult to understand the problem.
0
 

Author Comment

by:vcharles
ID: 37807723
OK, I will check with componentone. If no solution, I may need to use the regular Grid.

Thanks,

Victor
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question