This is a migrated thread and some comments may be shown as answers.

Exception when dragging GridViewRow over ScheduleView

3 Answers 82 Views
ScheduleView
This is a migrated thread and some comments may be shown as answers.
Pavel
Top achievements
Rank 1
Pavel asked on 07 Mar 2011, 03:16 AM
I´m using RadDocking. In one RadPane is GridView, in second ScheduleView. I use dragging items from GridView for reordering rows in GridView according to demo "GridView - Reorder rows". I´m using version 2010.3.1314.35
When I drag GridViewRow over ScheduleView, NullReferrence exeption appears. I think, it´s a bug. See attached printscreens for more information.

System.NullReferenceException was unhandled
  Message=Object reference not set to an instance of an object.
  Source=Telerik.Windows.Controls.ScheduleView
  StackTrace:
       at Telerik.Windows.Controls.DefaultDragDropBehavior.GetDragDropState(Object payload, IDataObject dragDataObject, IEnumerable destinationAppointmentsSource, IServiceProvider serviceProvider) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\ScheduleView\ScheduleView\DragDropBehavior\DefaultDragDropBehavior.cs:line 43
       at Telerik.Windows.Controls.DragDropHelper.GetStateForDragDrop(Object payload, DataObject dropDataObject, Point relativeDragPoint) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\ScheduleView\ScheduleView\DragDropBehavior\Helpers\DragDropHelper.cs:line 660
       at Telerik.Windows.Controls.DragDropHelper.OnDropQuery(Object sender, DragDropQueryEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Controls\ScheduleView\ScheduleView\DragDropBehavior\Helpers\DragDropHelper.cs:line 402
       at Telerik.Windows.Controls.DragDrop.DragDropQueryEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Controls\DragDrop\DragDropQueryEventArgs.cs:line 50
       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(DependencyObject sender, RoutedEventArgs args)
       at System.Windows.UIElement.RaiseEvent(RoutedEventArgs e)
       at Telerik.Windows.Controls.DragDrop.RadDragAndDropManager.DragDropProvider_DropQuery(Object sender, DragDropEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Controls\DragDrop\RadDragAndDropManager.cs:line 314
       at Telerik.Windows.Controls.DragDrop.DragDropProviderBase.RaiseDropQuery() in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Controls\DragDrop\DragProviders\DragDropProviderBase.cs:line 182
       at Telerik.Windows.Controls.DragDrop.SimulatedDragDropProvider.OnRealDrag(IMouseEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Controls\DragDrop\DragProviders\SimulatedDragDropProvider.cs:line 469
       at Telerik.Windows.Controls.DragDrop.SimulatedDragDropProvider.OnCoverRectangleMouseMoveInternal(IMouseEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Controls\DragDrop\DragProviders\SimulatedDragDropProvider.cs:line 361
       at Telerik.Windows.Controls.DragDrop.WPFSimulatedDragDropProvider.OnCoverRectangleMouseMove(Object sender, MouseEventArgs e) in c:\Builds\WPF_Scrum\Release_WPF\Sources\Development\Core\Controls\DragDrop\DragProviders\WPFSimulatedDragDropProvider.cs:line 380
       at System.Windows.Input.MouseEventArgs.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(DependencyObject sender, RoutedEventArgs args)
       at System.Windows.UIElement.RaiseTrustedEvent(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.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
       at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
       at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
       at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
       at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)
       at System.Windows.Threading.Dispatcher.InvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Int32 numArgs)
       at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)
       at MS.Win32.UnsafeNativeMethods.DispatchMessage(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.RunDispatcher(Object ignore)
       at System.Windows.Application.RunInternal(Window window)
       at System.Windows.Application.Run(Window window)
       at System.Windows.Application.Run()
       at Administration2010.App.Main() in D:\ZSVNN\Administration2010\Administration2010\obj\x86\Debug\App.g.cs:line 50
       at System.AppDomain._nExecuteAssembly(RuntimeAssembly 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, Boolean ignoreSyncCtx)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
       at System.Threading.ThreadHelper.ThreadStart()
  InnerException:

3 Answers, 1 is accepted

Sort by
0
Rosi
Telerik team
answered on 08 Mar 2011, 10:46 AM
Hi Pavel,

Dragging from any control to RadScheduleView should works as expected.  An example illustrating the behavior is shown here. That is why we think that is possible a specific configuration in your project to cause the exception.

To find the source of the issue I suggest you send us sample running project illustrating the problem. We will test it locally and provide you with a solution or more technical instructions.

Regards,
Rosi
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
0
Pavel
Top achievements
Rank 1
answered on 08 Mar 2011, 06:06 PM

Sample running project  is available HERE

Exception occurs when dragging GridViewRow or GridView Coumn Header over ScheduleView. I tried it in Win XP and Win 7 with the same exception. I don´t need to Drop from GridView to ScheduleView. I use dragging just only to reorder rows/columns in GridView.

0
Valeri Hristov
Telerik team
answered on 09 Mar 2011, 05:38 PM
Hi Pavel,

Thank you for the project, it was really helpful. The problem will be fixed in the Q1 2011 release (the fix is present in the latest binaries that we have).

Greetings,
Valeri Hristov
the Telerik team
Registration for Q1 2011 What’s New Webinar Week is now open. Mark your calendar for the week starting March 21st and book your seat for a walk through all the exciting stuff we ship with the new release!
Tags
ScheduleView
Asked by
Pavel
Top achievements
Rank 1
Answers by
Rosi
Telerik team
Pavel
Top achievements
Rank 1
Valeri Hristov
Telerik team
Share this question
or