FlexGrid 2 exceptions

Posted by: info on 2 March 2022, 6:14 am EST

    • Post Options:
    • Link

    Posted 2 March 2022, 6:14 am EST - Updated 4 October 2022, 8:33 am EST

    Hello.

    Exception occures in these scenario.

    Could you fix?

    C1.WPF.Grid.Ja 6.0.20213.162

    .NET 6

    A.

    1. Edit & Push Enter Key.

    2. Row is focused.

    3. Clear list

    4.Can not Edit & Sort. System.ArgumentOutOfRangeException occures

    B.

    1. TextBox is edited, and Clear List.

    2. Exception occures

    System.ArgumentOutOfRangeException: ‘Index was out of range. Must be non-negative and less than the size of the collection. Arg_ParamName_Name’

    20220302FlexGrid_OutOfRange.zip

  • Posted 2 March 2022, 7:24 am EST

    Hi,

    Thanks for providing the sample and snapshots.

    You need to finish editing before modifying collection source of flexgrid. In your scenario, Collection is modifying without exiting from the edit mode.

    You can end edit before Reload as:

    
    	 grid.FinishRowEditing();
             _model.Reload();
    
    

    Please refer the attached modified sample for the same : FlexGrid_OutOfRange_Mod.zip

    Best Regards,

    Nitin

  • Posted 2 March 2022, 9:07 pm EST

    Thank you!

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels