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

System.NullReferenceException occuring when using Telerik for WPF especially when the WPF application is published via RDS

5 Answers 538 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Dharit
Top achievements
Rank 1
Dharit asked on 28 May 2020, 09:19 AM

Hello,

 

We have a desktop based WPF application that is published via RDS. Randomly throughout the day the application crashes with below exception. The error is random and the user of the application or the development\support team of the application is unable to recreate this at will. Any insights regarding this would be helpful. Thank you in advance!

 

Exception

******************************************

Application: ntierHealth.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.NullReferenceException
   at Telerik.Windows.Controls.WindowHost.GetGlobalMousePosition(System.Windows.UIElement, System.Windows.Input.MouseEventArgs)
   at Telerik.Windows.Controls.InternalWindow.DragBehavior.OnElementMouseLeftButtonUp(System.Object, System.Windows.Input.MouseButtonEventArgs)
   at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(System.Delegate, System.Object)
   at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
   at System.Windows.UIElement.ReRaiseEventAs(System.Windows.DependencyObject, System.Windows.RoutedEventArgs, System.Windows.RoutedEvent)
   at System.Windows.UIElement.OnMouseUpThunk(System.Object, System.Windows.Input.MouseButtonEventArgs)
   at System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(System.Delegate, System.Object)
   at System.Windows.RoutedEventArgs.InvokeHandler(System.Delegate, System.Object)
   at System.Windows.RoutedEventHandlerInfo.InvokeHandler(System.Object, System.Windows.RoutedEventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(System.Object, System.Windows.RoutedEventArgs, Boolean)
   at System.Windows.UIElement.RaiseEventImpl(System.Windows.DependencyObject, System.Windows.RoutedEventArgs)
   at System.Windows.UIElement.RaiseTrustedEvent(System.Windows.RoutedEventArgs)
   at System.Windows.UIElement.RaiseEvent(System.Windows.RoutedEventArgs, Boolean)
   at System.Windows.Input.InputManager.ProcessStagingArea()
   at System.Windows.Input.InputManager.ProcessInput(System.Windows.Input.InputEventArgs)
   at System.Windows.Input.InputProviderSite.ReportInput(System.Windows.Input.InputReport)
   at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr, System.Windows.Input.InputMode, Int32, System.Windows.Input.RawMouseActions, Int32, Int32, Int32)
   at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr, MS.Internal.Interop.WindowMessage, IntPtr, IntPtr, Boolean ByRef)
   at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
   at MS.Win32.HwndWrapper.WndProc(IntPtr, Int32, IntPtr, IntPtr, Boolean ByRef)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(System.Object)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(System.Delegate, System.Object, Int32)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(System.Object, System.Delegate, System.Object, Int32, System.Delegate)
   at System.Windows.Threading.Dispatcher.LegacyInvokeImpl(System.Windows.Threading.DispatcherPriority, System.TimeSpan, System.Delegate, System.Object, Int32)
   at MS.Win32.HwndSubclass.SubclassWndProc(IntPtr, Int32, IntPtr, IntPtr)
   at MS.Win32.UnsafeNativeMethods.DispatchMessage(System.Windows.Interop.MSG ByRef)
   at System.Windows.Threading.Dispatcher.PushFrameImpl(System.Windows.Threading.DispatcherFrame)
   at System.Windows.Threading.Dispatcher.PushFrame(System.Windows.Threading.DispatcherFrame)
   at System.Windows.Application.RunDispatcher(System.Object)
   at System.Windows.Application.RunInternal(System.Windows.Window)
   at System.Windows.Application.Run(System.Windows.Window)
   at Mdrx.PM.Client.Shell.App.Main()

******************************************

5 Answers, 1 is accepted

Sort by
0
Kalin
Telerik team
answered on 02 Jun 2020, 08:53 AM

Hi Dharit,

Thank for contacting us.

The same exception has been reported few times from different customers, however we haven't been able to reproduce it on our side. So any additional information you can share would be really helpful - are you using Docking or RadWindow, what is the exact scenario? Can you share some xaml/code of the areas that include the control that throws the exception? Meanwhile we will investigate the methods in the stack trace and see whether we would be able to introduce a blind fix for that.

I'm looking forward to hearing from you.

Regards,
Kalin
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
0
Dharit
Top achievements
Rank 1
answered on 02 Jun 2020, 12:44 PM

Hi,

Thank you for replying. As we are unable to recreate this issue at will there are many unknowns at this point however I am answering the questions that I know for sure.

 

We are using "RadDocking" from the control dll.  Since I am not sure about the exact steps to recreate, I am not sure about the XAML code that can cause this issue. Is there a way to collect it from client machine where they are facing this issue?

-Dharit

0
Kalin
Telerik team
answered on 04 Jun 2020, 03:33 PM

Hello Dharit,

We added blind fix that we hope would solve the problem for you - the fix will be available with the internal build next Monday. When possible please test it and let us know if you observe the same issue once again.

Hope this will work for you.

Regards,
Kalin
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
0
Dharit
Top achievements
Rank 1
answered on 11 Jun 2020, 06:37 AM

HI Kalin,

Thank you so much for response. We are thrilled to learn that a possible fix is in sight.

Can you please help me get the build with fix? Also, our dll is of older version (of 2015), will the new dll be compatible with our older version of application?

-Dharit

0
Kalin
Telerik team
answered on 16 Jun 2020, 07:08 AM

Hi Dharit,

You can get the fix with the latest internal build (see this article) or you could wait for the service we will be release this week and install it from the MSI as explained here. Please review this section of the help documentation - there are few different ways to get latest official version.

As for the compatibility - what I can suggest you would to run firstly our Upgrade Api Analyizer tool that will show if there any breaking changes in the API. However we are avoiding to make breaking changes, so I don't think you would have any issues. 

Please let us know if you encounter difficulties with the upgrade process - we will be glad to help. Once again - I hope the fix will resolve the observed issue - please share your feedback when possible.

Regards,
Kalin
Progress Telerik

Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
Our thoughts here at Progress are with those affected by the outbreak.
Tags
General Discussions
Asked by
Dharit
Top achievements
Rank 1
Answers by
Kalin
Telerik team
Dharit
Top achievements
Rank 1
Share this question
or