NullReferenceException in IdentifyGraphicsOverlayResult.get_Graphics()

371
0
05-31-2018 04:42 AM
ThomasLindegaard
New Contributor

Hi,

Using arcgis runtime 100.2 (WPF) and it generally looks good. We do see a null reference exception thrown from it every now and then, though. Does anyone else experience this? It's caught in the xaml's codebehind and thrown while getting graphics on IdentifyGraphicsOverlayResult. Here's a stacktrace, let me know if there's a patch or someway to prevent this (currently we catch this exact exception and swallows it);

======== Exception messages ========
1:System.NullReferenceException. Message: Object reference not set to an instance of an object.. Properties: .

======== Stack trace =========
at Esri.ArcGISRuntime.Internal.GraphicList.CreateInstanceFromElement(CoreElement coreElement)
at Esri.ArcGISRuntime.RuntimeCollection`1.Initialize()
at Esri.ArcGISRuntime.Data.IdentifyGraphicsOverlayResult.<get_Graphics>b__9_0()
at System.Threading.LazyInitializer.EnsureInitializedCore(T& target, Boolean& initialized, Object& syncLock, Func`1 valueFactory)
at Esri.ArcGISRuntime.Data.IdentifyGraphicsOverlayResult.get_Graphics()
at WorkBridge.Modules.Equipment.Cli.EquipmentMap.EquipmentMapView.<HandleEquipmentTappedEvent>d__19.MoveNext() in C:\WKB\20.Branch\AMS\3G\10.Src\Modules\Equipment\EquipmentCli\WKBEquipment.Cli\EquipmentMap\EquipmentMapView.xaml.cs:line 148
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

best of luck!

Thomas Lindegaard

0 Kudos
0 Replies