How to get updated FormView values ​​when processing a form?

In ItemUpdating, I can get the values ​​of the fields, but I can not get only the updated values.

Is there a better way to do this than the method below?

protected void fwHotelDetails_ItemUpdating(Object sender, FormViewUpdateEventArgs e)
{
    TextBox tbName = (TextBox)fwHotelDetails.Row.FindControl("input_name");
    MessageLabel.Text = "This works..." + tbName.Text;
}
+3
source share
1 answer

Yes. The second parameter of the event handler ( FormViewUpdateEventArgs e) has the following properties:

  • Keys
  • Newvalues
  • Oldvalues

Additional information about msdn

Hope this helps

+3
source

Source: https://habr.com/ru/post/1718552/


All Articles