The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
I am having a problem with the GridGroupingControl. I am using it in an inherited form, where the Grid was added to the base class. For some reason, when the form loads i get the following exception:
Item has already been added. Key in dictionary: "Row 1Summary 1" Key being added: "Row 1Summary 1".
The exception is:
See the end of this message for details on invoking just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text ************** System.ArgumentException: Item has already been added. Key in dictionary: "Row 1Summary 1" Key being added: "Row 1Summary 1" at System.Collections.SortedList.Add(Object key, Object value) at Syncfusion.Grouping.SummaryDescriptorCollection.Find(String name) at Syncfusion.Grouping.SummaryDescriptorCollection.IndexOf(String name) at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.GetColumnMaxLength(GridColumnDescriptor column, FieldDescriptor rfield) at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.GetColumnMaxLength(GridColumnDescriptor column) at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.GetPreferredColumnWidth(Graphics g, GridColumnDescriptor column, Int32 maxWidth) at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.GetPreferredColumnWidth(Graphics g, GridColumnDescriptor column) at Syncfusion.Windows.Forms.Grid.Grouping.GridTableModel.UpdateColumnWidths(Boolean force) at Syncfusion.Windows.Forms.Grid.Grouping.GridTableModel.UpdateColumnWidths() at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.VisibleColumns_TotalWidthRequest(Object sender, CancelEventArgs e) at Syncfusion.Windows.Forms.Grid.Grouping.GridVisibleColumnDescriptorCollection.OnTotalWidthRequest(CancelEventArgs e) at Syncfusion.Windows.Forms.Grid.Grouping.GridVisibleColumnDescriptorCollection.get_TotalWidth() at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.GetHorizontalScrollWidth(Boolean isNested) at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.GetHorizontalScrollWidth() at Syncfusion.Windows.Forms.Grid.Grouping.GridTable.get_LastColumnWidth() at Syncfusion.Windows.Forms.Grid.Grouping.GridTableModel.OnQueryColWidth(GridRowColSizeEventArgs e) at Syncfusion.Windows.Forms.Grid.GridModel.RaiseQueryColWidth(GridRowColSizeEventArgs e) at Syncfusion.Windows.Forms.Grid.GridModelColWidthsIndexer.OnQuerySize(GridRowColSizeEventArgs e) at Syncfusion.Windows.Forms.Grid.GridModelRowColSizeIndexer.GetSize(Int32 index) at Syncfusion.Windows.Forms.Grid.GridModelRowColSizeIndexer.get_Item(Int32 index) at Syncfusion.Windows.Forms.Grid.GridControlBase.GetColWidth(Int32 colIndex) at Syncfusion.Windows.Forms.Grid.GridViewLayout.Initialize() at Syncfusion.Windows.Forms.Grid.GridViewLayout.DemandInitialize() at Syncfusion.Windows.Forms.Grid.GridViewLayout.get_LastVisibleRow() at Syncfusion.Windows.Forms.Grid.GridControlBase.set_GridBounds(Rectangle value) at Syncfusion.Windows.Forms.Grid.GridControlBase.DrawGrid(Graphics g, Rectangle bounds, Boolean drawCurrentCell, Boolean shouldClip) at Syncfusion.Windows.Forms.Grid.Grouping.GridGroupingControl.OptimizeLoadTime() at Syncfusion.Windows.Forms.Grid.Grouping.GridGroupingControl.f_Load(Object sender, EventArgs e) at System.EventHandler.Invoke(Object sender, EventArgs e) at System.Windows.Forms.Form.OnLoad(EventArgs e) at System.Windows.Forms.Form.OnCreateControl() at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible) at System.Windows.Forms.Control.CreateControl() at System.Windows.Forms.Control.WmShowWindow(Message& m) at System.Windows.Forms.Control.WndProc(Message& m) at System.Windows.Forms.ScrollableControl.WndProc(Message& m) at System.Windows.Forms.ContainerControl.WndProc(Message& m) at System.Windows.Forms.Form.WmShowWindow(Message& m) at System.Windows.Forms.Form.WndProc(Message& m) at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m) at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m) at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntP
Since this is all in syncfusion code, i don''t know where to start.
Unfortunetly, any time I make changes using the designer, that line will be added back again. Is there any way to prevent this.
ADAdministrator Syncfusion Team August 2, 2006 03:00 PM UTC
After some more investigation...
I have a SummaryRow defined in my base class. For some reason, every time i make changes in the designer, it will duplicate the SummaryRow in the inherited class. Not only does it dupplicate it, it will add the same entry every time I make a change in the designer.
I can fix it by deleting the SummaryRows in the inherited class, but I have to do this every time I make a change.