C#: GridViewUpdateEventArgs.NewValues Property getting new value from Grid view
Eg:
Write the Selected Row updating event on the Gridview.
protected void SelectedRowUpdating_Clicked(object sender, GridViewUpdateEventArgs e)
{
String tempQty = String.Empty;
// Iterate through the NewValues collection and HTML encode all
// user-provided values before updating the data source.
foreach (DictionaryEntry entry in e.NewValues)
{
e.NewValues[entry.Key] = Server.HtmlEncode(entry.Value.ToString());
tempQty = entry.Key.ToString();
tempQty = entry.Value.ToString();
}
AxGridView3.EditIndex = -1; EditDeleteSelectedOrder(tempQty);
}
Eg:
Write the Selected Row updating event on the Gridview.
protected void SelectedRowUpdating_Clicked(object sender, GridViewUpdateEventArgs e)
{
String tempQty = String.Empty;
// Iterate through the NewValues collection and HTML encode all
// user-provided values before updating the data source.
foreach (DictionaryEntry entry in e.NewValues)
{
e.NewValues[entry.Key] = Server.HtmlEncode(entry.Value.ToString());
tempQty = entry.Key.ToString();
tempQty = entry.Value.ToString();
}
AxGridView3.EditIndex = -1; EditDeleteSelectedOrder(tempQty);
}
No comments:
Post a Comment