Articles in this section
Category / Section

How to insert custom button inside Navigation bar to insert new row to Grid?

1 min read

You can Insert new row using the Navigation bar with the custom ButtonBarItemType. Please use the below code snippet to achieve this:

C#

   protected void GridGroupingControl1_BarButtonItemClicked(object source, Syncfusion.Web.UI.WebControls.Grid.Grouping.ButtonBarItemClickEventArgs e)

    {

        if (e.ButtonBarItem.Text == "Insert")

        {

this.GridGroupingControl1.TableDescriptor.AllowNew = true;

        }

}

VB

 Protected Sub GridGroupingControl1_BarButtonItemClicked(ByVal source As Object, ByVal e As Syncfusion.Web.UI.WebControls.Grid.Grouping.ButtonBarItemClickEventArgs)

  If e.ButtonBarItem.Text = "Insert" Then

Me.GridGroupingControl1.TableDescriptor.AllowNew = True

  End If

  End Sub

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied