Vignesh Kumar

Vignesh Kumar

  • NA
  • 1k
  • 415.9k

Add New Item in GridView

Aug 8 2013 6:38 AM
Hi,
I have a "Add New" button inside the grid and I am not able to add items to the grid.
protected void ResultGridView_RowCommand(object sender, GridViewCommandEventArgs e)
  {
  try
  {
  if (e.CommandName.Equals("AddNew"))
  {
  TextBox Lob = (TextBox)GridView1.FooterRow.FindControl("txtLob");
  TextBox LobDescription = (TextBox)GridView1.FooterRow.FindControl("txtLobDescription");
  LOBDataBO.InsertLOBValues(Lob.Text, LobDescription.Text);
  FillVendorGrid();
  }
  }
  catch (Exception exc)
  {
  Logger.LogError(exc, MethodBase.GetCurrentMethod().ToString());
  UtilityMethods.RedirectToErrorPage(Constants.Message_ErrorProcessingRequest);
  }
  }

Attachment: savesendmail.zip

Answers (6)