We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

GridControl - Exception "Grid is in updating mode"

Thread ID:

Created:

Updated:

Platform:

Replies:

102108 Dec 27,2011 05:33 AM UTC Dec 29,2011 07:23 AM UTC WinForms 2
loading
Tags: GridControl
Patz
Asked On December 27, 2011 05:33 AM UTC

Hi, I'm using Syncfusion 6.102.0.34.

In GridControl, when calling GridControl.Cols.RemoveRange(rangeStart, rangeStart), exception "Grid is in updating mode" is thrown. And GridControl shows up a big red cross.

But when checking GridControl.Updating, it's false. Just inside the RemoveRange call, GridControl.Updating becomes true & exception thrown.

The call to GridControl.Cols.RemoveRange is quite straight forward. Just click a button, the button click callback calls the RemoveRange.

Any help would be appreciate. Thanks!

The call stack is:
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControlBase.OnPaint(System.Windows.Forms.PaintEventArgs pe) + 0x35e bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.PaintWithErrorHandling(System.Windows.Forms.PaintEventArgs e = {ClipRectangle = {X=0,Y=0,Width=901,Height=103}}, short layer, bool disposeEventArgs = false) + 0x9a bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.OnPrint(System.Windows.Forms.PaintEventArgs e) + 0x60 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.WmPrintClient(ref System.Windows.Forms.Message m) + 0x97 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.WndProc(ref System.Windows.Forms.Message m) + 0x3e1 bytes
Syncfusion.Shared.Base.dll!Syncfusion.Windows.Forms.ScrollControl.WndProc(ref System.Windows.Forms.Message msg) + 0x350 bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControlBase.WndProc(ref System.Windows.Forms.Message msg) + 0x2a1 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.ControlNativeWindow.OnMessage(ref System.Windows.Forms.Message m) + 0x10 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.ControlNativeWindow.WndProc(ref System.Windows.Forms.Message m) + 0x31 bytes
System.Windows.Forms.dll!System.Windows.Forms.NativeWindow.DebuggableCallback(System.IntPtr hWnd, int msg = 792, System.IntPtr wparam, System.IntPtr lparam) + 0x57 bytes
[Native to Managed Transition]
[Managed to Native Transition]
System.Windows.Forms.dll!System.Windows.Forms.NativeWindow.DefWndProc(ref System.Windows.Forms.Message m = {msg=0xf (WM_PAINT) hwnd=0x100acc wparam=0x0 lparam=0x0 result=0x0}) + 0x93 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.DefWndProc(ref System.Windows.Forms.Message m) + 0xc bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.WndProc(ref System.Windows.Forms.Message m) + 0x3bf bytes
System.Windows.Forms.dll!System.Windows.Forms.DateTimePicker.WndProc(ref System.Windows.Forms.Message m) + 0x70 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.ControlNativeWindow.OnMessage(ref System.Windows.Forms.Message m) + 0x10 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.ControlNativeWindow.WndProc(ref System.Windows.Forms.Message m) + 0x31 bytes
System.Windows.Forms.dll!System.Windows.Forms.NativeWindow.DebuggableCallback(System.IntPtr hWnd, int msg = 15, System.IntPtr wparam, System.IntPtr lparam) + 0x57 bytes
[Native to Managed Transition]
[Managed to Native Transition]
System.Windows.Forms.dll!System.Windows.Forms.Control.Update() + 0x15 bytes
System.Windows.Forms.dll!System.Windows.Forms.Control.Refresh() + 0x19 bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControlBase.Refresh(bool fromModel) + 0x4b bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControl.Refresh(bool fromModel) + 0x27 bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControlBase.ModelRefreshRequest(object sender, System.EventArgs e) + 0x29 bytes
[Native to Managed Transition]
[Managed to Native Transition]
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridModel.Refresh() + 0x1c bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControl.Refresh(bool fromModel) + 0x19 bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControlBase.Refresh() + 0xd bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridControlBase.ModelColsRangeRemoved(object sender, Syncfusion.Windows.Forms.Grid.GridRangeRemovedEventArgs e) + 0x2e0 bytes
[Native to Managed Transition]
[Managed to Native Transition]
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridModel.OnColsRemoved(Syncfusion.Windows.Forms.Grid.GridRangeRemovedEventArgs e) + 0x44 bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridModel.RaiseColsRemoved(Syncfusion.Windows.Forms.Grid.GridRangeRemovedEventArgs e) + 0xb bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridModelColOperations.OnRangeRemoved(Syncfusion.Windows.Forms.Grid.GridRangeRemovedEventArgs e) + 0x2c bytes
Syncfusion.Grid.Windows.dll!Syncfusion.Windows.Forms.Grid.GridModelRowColOperations.RemoveRange(int from = 5, int last = 5) + 0x336 bytes
ParameterAccessLayer.dll!***.ZoneEditorControl.DeleteParameterZone() Line 1970 + 0x35 bytes C#
> ParameterAccessLayer.dll!***.ZoningLayout.m_ToolBarParameter_ButtonClick(object sender = {System.Windows.Forms.ToolBar, Buttons.Count: 11, Buttons[0]: ToolBarButton: , Style: PushButton}, System.Windows.Forms.ToolBarButtonClickEventArgs e = {System.Windows.Forms.ToolBarButtonClickEventArgs}) Line 1668 + 0x13 bytes C#



Patz
Replied On December 28, 2011 07:39 AM UTC

I found the exception is only thrown when current cell is set to a data time picker cell. The cell template is from our DateTimePickerCell.

In the DateTimePickerCell.OnInitialize function, I found that CurrentCell.BeginEdit() is called, however, CurrentCell.EndEdit is never called. I think this is the cause of this problem.

If the CurrentCell.BeginEdit is removed, the cell cannot be edit.

I tried move the BeginEdit/EndEdit to the OnActivated/OnDeactivating, but the OnActivated got called one more times than OnDeactivating, thus still cause asymmetrical BeginEdit/EndEdit calls.

Any suggestion about where & how to put the CurrentCell.BeginEdit/EndEdit? Thanks very much!



Mercy C [Syncfusion]
Replied On December 29, 2011 07:23 AM UTC

Hi,
Thanks for your interest in Syncfusion products.

This issue with Cols.RemoveRange has been resolved in our later version v9.4. So, please migrate to it.

Please let me know if you have any further concerns.

Regards,
Mercy.C



CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

or the page will be automatically redirected to sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;