Hello Syncfusion team,
Following https://stackoverflow.com/questions/66546568/cant-add-a-row-in-sfgrid-when-database-table-is-empty
Is this issue solved? as I face it also (Syncfusion Blazor 19.2.0.49)
Thanks,
Shay
I will send sample to support,
Shay
I'm having this issue with version 23.2.6.
I have an SfGrid bound to an empty table with the Add button on the toolbar. When I click the toolbar an exception is thrown:
[2023-11-30T07:03:10.578Z] Error: System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')
at System.Collections.Generic.List`1.get_Item(Int32 index)
at Syncfusion.Blazor.Grids.Internal.Edit`1.AddRecord(Object data, Nullable`1 index)
at Syncfusion.Blazor.Grids.SfGrid`1.AddRecordAsync()
at Syncfusion.Blazor.Grids.SfGrid`1.AddRecord()
at Syncfusion.Blazor.Grids.Internal.GridToolbar`1.ToolbarClickHandler(ClickEventArgs args)
at Microsoft.AspNetCore.Components.ComponentBase.CallStateHasChangedOnAsyncCompletion(Task task)
at Syncfusion.Blazor.Navigations.SfToolbar.TriggerClickEvent(MouseEventArgs e, Nullable`1 trgParentDataIndex, ItemModel clickedItem)
at Syncfusion.Blazor.Navigations.Internal.ToolbarContent.OnItemClick(MouseEventArgs e)
at Microsoft.AspNetCore.Components.ComponentBase.CallStateHasChangedOnAsyncCompletion(Task task)
at Microsoft.AspNetCore.Components.RenderTree.Renderer.GetErrorHandledTask(Task taskToHandle, ComponentState owningComponentState)
I am using .Net 7 in a Blazor Server application.
Your help is appreciated!
Thanks
Hi Michael,
Greetings from Syncfusion support.
We have prepared an simple sample using .Net7 with Blazor server. But we are unable to replicate the reported issue at our end. Kindly refer the below attached sample for your reference.
If you still face the reported issue then kindly share us the below details for additional information.
The above requested details will be very helpful for us to validate the reported issue at our end.
Regards,
Monisha