Selecting in GridView for DetailsView

Capodecina
Permabanned
Joined
31 Dec 2003
Posts
5,172
Location
Barrow-In-Furness
ASP.net question if the title didn't give it a way.

Having decided I don't like the way the GridView is when editing, I now want to do something else.

At the top of the page I have a DetailsView for inputting, below that is a GridView which displays data that has been entered previously.

When the user clicks edit, i'd like the information to appear in the above DetailsView for editing, if you follow?

Any guides or anything you guys can point me at?
 
Can't remember the code off the top of my head, but...

I'd have thought if your grid was, say:

Forename|Surname|Age

When they click "Edit", you get the details of CurrentRow.Item(0) and pass the value to the textbox above the grid. Do the same for CurrentRow.Item(1) to CurrentRow.Item(2).

Next to these textboxes you'd have a submit button, which when clicked, passes the information from the textboxes into CurrentRow.Item(0) to CurrentRow.Item(2) and a wee bit of javascript to submit the change on the row.

Is that what you mean?
 
Back
Top Bottom