Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
140
UltraGrid TemplateAddRow problem
posted

I am using infragistics v7.2. I am facing problem with the UltraGrid. If I click on the TemplateAddRow, do not enter anything and click back to an another row, then the grid will cancels the row by calling CancelEdit mehtod. This deletes the row from datasource. But the row will remain visible on ultragrid. Now if user edits this row and move to new template row that is created at bottom of grid, the changes user made in previous row are lost.

My datasource implements IBindingList.

Please help.

Following is the statck trace.

TestNamespace.TableRowCollection.RemoveAt(Int32 index)
   at System.Windows.Forms.CurrencyManager.RemoveAt(Int32 index)
   at Infragistics.Win.UltraWinGrid.UltraGridRow.DeleteHelper()
   at Infragistics.Win.UltraWinGrid.UltraGridRow.CancelEdit()
   at Infragistics.Win.UltraWinGrid.UltraGrid.OnActiveRowCleared(Boolean update)
   at Infragistics.Win.UltraWinGrid.UltraGridBase.SetActiveRow(UltraGridRow row, Boolean scrollIntoView)
   at Infragistics.Win.UltraWinGrid.UltraGridCell.Activate()
   at Infragistics.Win.UltraWinGrid.UltraGridCell.SetFocusAndActivate(Boolean byMouse, Boolean enterEditMode, Boolean byTabKey)
   at Infragistics.Win.UltraWinGrid.UltraGridCell.SetFocusAndActivate(Boolean byMouse, Boolean enterEditMode)
   at Infragistics.Win.UltraWinGrid.CellUIElementBase.OnEmbeddableElementMouseDown(Object sender, EmbeddableMouseDownEventArgs e)
   at Infragistics.Win.UltraWinGrid.GridEmbeddableEditorOwnerInfoBase.OnEditorMouseDown(EmbeddableUIElementBase embeddableElem, EmbeddableMouseDownEventArgs e)
   at Infragistics.Win.EmbeddableUIElementBase.RaiseMouseDownEvent(EmbeddableMouseDownEventArgs e)
   at Infragistics.Win.FormattedLinkLabel.FormattedTextUIElement.ProcessMouseDownHelper(EmbeddableUIElementBase editorElem, MouseEventArgs mouseArgs, Boolean adjustableArea, UIElement& captureMouseForElement, Boolean& notifyParent)
   at Infragistics.Win.FormattedLinkLabel.FormattedTextUIElement.OnMouseDown(MouseEventArgs mouseArgs, Boolean adjustableArea, UIElement& captureMouseForElement)
   at Infragistics.Win.ControlUIElementBase.ProcessMouseDownHelper(Object sender, MouseEventArgs e)
   at Infragistics.Win.ControlUIElementBase.ProcessMouseDown(Object sender, MouseEventArgs e)
   at Infragistics.Win.Utilities.ProcessEvent(Control control, ProcessEvent eventToProcess, EventArgs e)
   at Infragistics.Win.UltraControlBase.OnMouseDown(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseDown(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.NativeWindow.DefWndProc(Message& m)
   at System.Windows.Forms.NativeWindow.WndProc(Message& m)
   at Infragistics.Win.EditorWithMask.AccessibleTextManager.AccessibleTextSubclasser.WndProc(Message& msg)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
   at System.Windows.Forms.NativeWindow.DefWndProc(Message& m)
   at System.Windows.Forms.NativeWindow.WndProc(Message& m)
   at Infragistics.Win.FormattedLinkLabel.FormattedLinkEditor.AccessibleTextManager.AccessibleTextSubclasser.WndProc(Message& msg)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

 

 

Parents
  • 469350
    Suggested Answer
    Offline posted

    What is your grid's DataSource? You say it implements IBindingList... does that mean this is a custom object where you implemented IBindingList yourself? If so, then my guess is that your IBindingList implementation is not sending the property notifications after the row is cancelled.

Reply Children