Posted 17 April 2024, 2:00 pm EST
I am encountering an issue with Spread.NET where I cannot remove a row from a group. According to the documentation, the GroupDataModel class does not support direct modifications to the row or column count. It suggests using the original data model methods for adding or removing rows or columns.
However, the GroupDataModel.TargetModel property returns an ISheetDataModel, which does not provide methods to remove rows. Additionally, the underlying type of TargetModel is WorksheetDataModel, which is an internal class with inaccessible members.
Expected Behavior: There should be a method or workaround to remove rows from a group using the GroupDataModel or through its TargetModel property.
Steps to Reproduce:
Create a group in the worksheet.
Attempt to remove a row from the group using the methods provided by GroupDataModel.
Documentation Reference: The documentation states: “The GroupDataModel does not support changing the column or row count. To add or remove columns or rows, you need to call the original data model methods. You can access the original data model using the TargetModel property of the GroupDataModel class.”
Could you please provide guidance or a workaround on how to remove rows from a group in this scenario?