Home Forums WPF controls Xceed DataGrid for WPF NullReferenceException – Datagrid version 1.4 (Is it a bug?)

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • User (Old forums)
    Member
    Post count: 23064
    #26091 |

    I am using the Datagrid version 1.4 and am getting a NullReferenceException which crashes my application. My grid is bound to an SQL database using Linq. Several of the Columns are numbers, so as a test, I enter a cell in a row (which is now selected and in EditMode) and type letters in a number column. I then tab across the grid on the same row and enter letters in several other number columns and then hit Enter. It now crashes the whole application with the NullReferenceException error. If I enter invalid data in only one column and then hit enter, the datagrid behaves and gives me the validation error indicator as expected. Is this a bug? Please Help!

    The full error below:
    System.NullReferenceException was unhandled
    Message=”Object reference not set to an instance of an object.”
    Source=”Xceed.Wpf.DataGrid”
    StackTrace:
    at Xceed.Wpf.DataGrid.DataGridCollectionView.DeferredOperationManager.Process(Boolean processAll)
    at Xceed.Wpf.DataGrid.DataGridCollectionView.DeferredOperationManager.Process()
    at Xceed.Wpf.DataGrid.DataGridCollectionView.DeferRefreshHelper.Dispose()
    at System.Windows.Controls.ItemCollection.EndDefer()
    at System.Windows.Controls.ItemCollection.DeferHelper.Dispose()
    at Xceed.Wpf.DataGrid.DataRow.EndEdit()
    at Xceed.Wpf.DataGrid.Row.OnEndEditExecuted(Object sender, ExecutedRoutedEventArgs e)
    at System.Windows.Input.CommandBinding.OnExecuted(Object sender, ExecutedRoutedEventArgs e)
    at System.Windows.Input.CommandManager.ExecuteCommandBinding(Object sender, ExecutedRoutedEventArgs e, CommandBinding commandBinding)
    at System.Windows.Input.CommandManager.FindCommandBinding(CommandBindingCollection commandBindings, Object sender, RoutedEventArgs e, ICommand command, Boolean execute)
    at System.Windows.Input.CommandManager.FindCommandBinding(Object sender, RoutedEventArgs e, ICommand command, Boolean execute)
    at System.Windows.Input.CommandManager.OnExecuted(Object sender, ExecutedRoutedEventArgs e)
    at System.Windows.UIElement.OnExecutedThunk(Object sender, ExecutedRoutedEventArgs e)
    at System.Windows.Input.ExecutedRoutedEventArgs.InvokeEventHandler(Delegate genericHandler, Object target)
    at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
    at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
    at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
    at System.Windows.UIElement.RaiseEventImpl(RoutedEventArgs args)
    at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
    at System.Windows.Input.RoutedCommand.ExecuteImpl(Object parameter, IInputElement target, Boolean userInitiated)
    at System.Windows.Input.RoutedCommand.ExecuteCore(Object parameter, IInputElement target, Boolean userInitiated)
    at System.Windows.Input.CommandManager.TranslateInput(IInputElement targetElement, InputEventArgs inputEventArgs)
    at System.Windows.UIElement.OnKeyDownThunk(Object sender, KeyEventArgs e)
    at System.Windows.Input.KeyEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)
    at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
    at System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)
    at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
    at System.Windows.UIElement.RaiseEventImpl(RoutedEventArgs args)
    at System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)
    at System.Windows.Input.InputManager.ProcessStagingArea()
    at System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)
    at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
    at System.Windows.Interop.HwndKeyboardInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawKeyboardActions actions, Int32 scanCode, Boolean isExtendedKey, Boolean isSystemKey, Int32 virtualKey)
    at System.Windows.Interop.HwndKeyboardInputProvider.ProcessKeyAction(MSG& msg, Boolean& handled)
    at System.Windows.Interop.HwndSource.CriticalTranslateAccelerator(MSG& msg, ModifierKeys modifiers)
    at System.Windows.Interop.HwndSource.OnPreprocessMessage(Object param)
    at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter)
    at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)
    at System.Windows.Threading.Dispatcher.InvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Boolean isSingleParameter)
    at System.Windows.Threading.Dispatcher.Invoke(DispatcherPriority priority, Delegate method, Object arg)
    at System.Windows.Interop.HwndSource.OnPreprocessMessageThunk(MSG& msg, Boolean& handled)
    at System.Windows.Interop.HwndSource.WeakEventPreprocessMessage.OnPreprocessMessage(MSG& msg, Boolean& handled)
    at System.Windows.Interop.ComponentDispatcherThread.RaiseThreadMessage(MSG& msg)
    at System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)
    at System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)
    at System.Windows.Threading.Dispatcher.Run()
    at System.Windows.Application.RunInternal(Window window)
    at System.Windows.Application.Run(Window window)
    at System.Windows.Application.Run()
    at SalesForecasting.App.Main() in C:\Projects\Source\Sales\SalesForecasting\obj\Debug\App.g.cs:line 0
    at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
    at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
    at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
    at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
    at System.Threading.ThreadHelper.ThreadStart()
    InnerException:

    Imported from legacy forums. Posted by Lance (had 2676 views)

    Xceed Support
    Member
    Post count: 5658

    Hi Lance,

    We were unable to reproduce the error you are reporting using SqlExpress and the Northwnd.mdf database with LinqToXML. We tried both version 1.4 and 2.0.

    Would it be possible for you to send us a small repro application? If so, send it to my attention (Jenny) at support@xceedsoft.com

    Imported from legacy forums. Posted by Jenny [Xceed] (had 154 views)

    User (Old forums)
    Member
    Post count: 23064

    Hi Jenny,

    It is fixed in version 2.0.

    Lance

    Imported from legacy forums. Posted by Lance (had 3595 views)

Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.