K
Kimberly
Hi - Is it impossible to define multiple datakeys for a datagrid? If
so - any ideas on how to update a record selected from a datagrid
using the Edit, Update, Cancel buttons? I can not get past trying to
define my datakeys. I can define one of the keys but what about the
other 2?? Here is my code...
//These fields make up my key
DateTime Event_start =
(DateTime)event_grid.DataKeys[e.Item.ItemIndex];
string plat = (TextBox)e.Item.Cells[1].Controls[0];
string system = (TextBox)e.Item.Cells[3].Controls[0];
//get the new values that were entered
event_text = (TextBox)e.Item.Cells[0].Controls[0];
Event_start_display = (TextBox)e.Item.Cells[2].Controls[0];
Notify_start = (TextBox)e.Item.Cells[4].Controls[0];
string Update_db = "update t_cust_appl_evt set ntfy_strt_dtm
='"+Notify_start.Text.Trim()+"'...
Any help is greatly appreciated.
so - any ideas on how to update a record selected from a datagrid
using the Edit, Update, Cancel buttons? I can not get past trying to
define my datakeys. I can define one of the keys but what about the
other 2?? Here is my code...
//These fields make up my key
DateTime Event_start =
(DateTime)event_grid.DataKeys[e.Item.ItemIndex];
string plat = (TextBox)e.Item.Cells[1].Controls[0];
string system = (TextBox)e.Item.Cells[3].Controls[0];
//get the new values that were entered
event_text = (TextBox)e.Item.Cells[0].Controls[0];
Event_start_display = (TextBox)e.Item.Cells[2].Controls[0];
Notify_start = (TextBox)e.Item.Cells[4].Controls[0];
string Update_db = "update t_cust_appl_evt set ntfy_strt_dtm
='"+Notify_start.Text.Trim()+"'...
Any help is greatly appreciated.