In-place Editing Problem

J

Jeff Petter

I'm having a problem getting the in-place editing feature to work with a datagrid. Unless I missed something, I think I followed the procedure, but when I click on the edit button, nothing happens. The code I'm using is:

private void DataGrid1_EditCommand(object source, System.Web.UI.WebControls.DataGridCommandEventArgs e)
{
DataGrid1.EditItemIndex = e.Item.ItemIndex;
BindDataGrid();
}

Is there something else that has to be set to make this work? If I manually change the EditItemIndex in the grid's properties, and run it, the specified row is editable, but I can't get the edit button columns to work. Does anyone have any ideas? I'd really appreciate any thoughts.

Thanks,
Jeff
 
J

Jos

Jeff Petter said:
I'm having a problem getting the in-place editing feature to work with a
datagrid. Unless I missed something, I think I followed the procedure, but
when I click on > the edit button, nothing happens. The code I'm using is:
private void DataGrid1_EditCommand(object source,
System.Web.UI.WebControls.DataGridCommandEventArgs e)
{
DataGrid1.EditItemIndex = e.Item.ItemIndex;
BindDataGrid();
}

Is there something else that has to be set to make this work?
If I manually change the EditItemIndex in the grid's properties,
and run it, the specified row is > editable, but I can't get the edit button columns to work.
Does anyone have any ideas? I'd really appreciate any thoughts.

Did you set the datagrid's EditCommand event handler to
DataGrid1_EditCommand?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top