New position on Grid Inline

Hello, I need urgent help; I have a Grid Inline where I insert data into it; The grid is not connected to a Datasource and therefore I just have to populate it; To insert a new line in Inline mode I do "Add" on the toolbar. After completing the line and I do Update on the toolbar, I want the grid to prepare for a new staff and then to insert more data into the grid as if it were an "ADD ". How can I solve?

Thank you 


Attachment: Grid_Edit_Inline_7fd60ba6.rar


1 Reply

PS Prathap Senthil Syncfusion Team November 11, 2022 02:14 PM UTC

Hi Biagio,


Greetings from Syncfusion support


Query:”  I want the grid to prepare for a new staff and then to insert more data into the grid as if it were an "ADD ". How can I solve?”


We prepared a sample based on your requirements using OnActionComplete event. ActionComplete will be triggered once the actions are completed.So kindly refer to the attached code snippet and solution sample for your reference.


Reference Link: https://blazor.syncfusion.com/documentation/datagrid/events#onactioncomplete


<GridEvents OnActionComplete="ActionCompletedHandler" TValue="Order"></GridEvents>

 

 

public void ActionCompletedHandler(ActionEventArgs<Order> args)

    {

        if(args.RequestType == Syncfusion.Blazor.Grids.Action.Save && args.Action == "Add" )

        {

             Grid.AddRecordAsync();

        }

    }


Regards,

Prathap S


Attachment: BlazorGrid_(2)_17e589e1.zip

Loader.
Up arrow icon