Jump to content

2 DataGrids


fr33kyd33ky

Recommended Posts

i'm having trouble having 2 datagrids on the same page. if i have an edit column, how do i make the codebehind tell which datagrid i'm trying to edit? right now, if i click the edit button for an item on datagrid2, the appropriate index on datagrid1 will be the one chosen for editing.

Link to comment
Share on other sites

i'm having trouble having 2 datagrids on the same page. if i have an edit column, how do i make the codebehind tell which datagrid i'm trying to edit? right now, if i click the edit button for an item on datagrid2, the appropriate index on datagrid1 will be the one chosen for editing.

If I understood your problem, if you are using built-in Edit Column of datagrid then there is no confusion bcoz when u click on edit of an item on datagrid2 you have the DataGrid2_EditCommand() event which will take care of your datagrid.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...