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

UWP ListView DragDrop error

4 Answers 27 Views
ListView
This is a migrated thread and some comments may be shown as answers.
Martin
Top achievements
Rank 1
Martin asked on 22 Dec 2020, 11:05 AM
System.ArgumentException: The parameter is incorrect.
value
   at Windows.UI.Xaml.UIElement.ReleasePointerCapture(Pointer value)
   at Telerik.UI.Xaml.Controls.Primitives.DragDrop.DragDropOperation.DragVisualHost_PointerReleased(Object sender, PointerRoutedEventArgs e)

Hello,
In the logs from customer devices, we found this exception. Any pointers on how to fix this?

Thank you.


4 Answers, 1 is accepted

Sort by
0
Didi
Telerik team
answered on 23 Dec 2020, 10:52 AM

Hi Martin,

I am sorry to hear about this issue. 

I have created a sample to test the scenario and I cannot reproduce the exception on my side. I have tested in release and in debug mode. Attached is my sample project. 

I did the steps you have described here: https://www.telerik.com/forums/uwp-drag-and-drop-out-of-current-view#Wc5zkYtAD0e_cCr2UnDCTQ 

When you try to to scroll using your mousewheel while drag-dropping a row, bugs will occur.

but I cannot reproduce the exception. 

Could you please modify the project base on your setup and send it back to me. Note - you should open a support ticket and attach the project there as in the forum only image attachments are allowed.

Regards,
Didi
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

0
Martin
Top achievements
Rank 1
answered on 26 Jan 2021, 02:54 PM
at Telerik.UI.Xaml.Controls.Primitives.DragDrop.Reorder.ReorderItemsCoordinator.GetRearrangePosition(IReorderItem targetItem, IReorderItem adjacentItem)
at Telerik.UI.Xaml.Controls.Primitives.DragDrop.Reorder.ReorderItemsCoordinator.UpdatePositionAndIndices(IReorderItem source, IReorderItem destination)
at Telerik.UI.Xaml.Controls.Data.ListViewReorderItemsCoordinator.UpdatePositionAndIndices(IReorderItem source, IReorderItem destination)
at Telerik.UI.Xaml.Controls.Primitives.DragDrop.Reorder.ReorderItemsCoordinator.ReorderItems(IReorderItem source, IReorderItem destination)
at Telerik.UI.Xaml.Controls.Primitives.DragDrop.Reorder.ReorderItemsCoordinator.ReorderItem(Int32 sourceIndex, IReorderItem destinationItem)
at Telerik.UI.Xaml.Controls.Data.ListView.RadListViewItem.Telerik.UI.Xaml.Controls.Primitives.DragDrop.IDragDropElement.DragOver(DragContext context)
at Telerik.UI.Xaml.Controls.Primitives.DragDrop.DragDropOperation.DragVisualHost_PointerMoved(Object sender, PointerRoutedEventArgs e)
I was able to cause an exception by the reorder operation, however a different one. There is something wrong inside the drag-drop code.

Here is the reproduction video + dnspy debug to see the exact issue.

Source code for the app:
0
Martin
Top achievements
Rank 1
answered on 26 Jan 2021, 03:09 PM

The exception in previous reply is a NullReferenceException.
______________________________________________________________

 

Hovewer we have collected another exception related to the drag-drop functionality our clients. I was unable to replicate this exception, but the stack traces, could be helpful to you.

System.NullReferenceException: Object reference not set to an instance of an object.
   at Telerik.UI.Xaml.Controls.Data.ListView.RadListViewItem.Telerik.UI.Xaml.Controls.Primitives.DragDrop.IDragDropElement.OnDragDropComplete(DragCompleteContext context)
   at Telerik.UI.Xaml.Controls.Primitives.DragDrop.DragDropOperation.EndDrag()
   at Telerik.UI.Xaml.Controls.Data.ListView.View.Controls.ListViewItemUIContainerGenerator.ClearContainerForItem(GeneratedItemModel element)
   at Telerik.UI.Xaml.Controls.Data.ContainerGeneration.ItemGeneratorBase`2.ClearContainerForItem(T decorator)
   at Telerik.UI.Xaml.Controls.Data.ContainerGeneration.ItemGeneratorBase`2.RecycleDecorator(T decorator)
   at Telerik.UI.Xaml.Controls.Data.ListView.Model.BaseLayoutStrategy.FullyRecycle()
   at Telerik.UI.Xaml.Controls.Data.ListViewUpdateService.ProcessUpdateFlags(Int32 flags)
   at Telerik.UI.Xaml.Controls.Primitives.UpdateServiceBase`1.DispatchUpdates()
   at Telerik.UI.Xaml.Controls.Primitives.UpdateServiceBase`1.OnUpdateCallback()

 

 

 

0
Didi
Telerik team
answered on 27 Jan 2021, 06:58 AM

Hello Martin,

I am sorry to hear about these exceptions. 

I have attached a sample project to this reply: https://www.telerik.com/forums/uwp-listview-dragdrop-error#pDMNcIl9IUKaj7ZiULcq6g . Have you tried to reproduce the issue inside the attached solution?

I noticed you have pasted some links inside your reply here https://www.telerik.com/forums/uwp-listview-dragdrop-error#_Ovz7p9wv0W9-IMRzsjjCA . Note that I have delete them from the thread.

If you want to send us a video and/or sample project, please open a support ticket and attach the files there.

I look forward to your reply.

Regards,
Didi
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.

Tags
ListView
Asked by
Martin
Top achievements
Rank 1
Answers by
Didi
Telerik team
Martin
Top achievements
Rank 1
Share this question
or