<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic 100.6 LocationDisplay always null in .NET Maps SDK Questions</title>
    <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174082#M1989</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I upgraded to 100.6 for Forms. With no other changes I started crashing when displaying the map because I set LocationDisplay.Enabled to true. However, LocationDisplay is now always null. This is on both Android and iOS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;on iOS, I have Always Enabled location permissions on and they are working because I am getting location updates.&amp;nbsp;&lt;/P&gt;&lt;P&gt;on Android, I have location permissions on as well and they are working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please advise,&lt;/P&gt;&lt;P&gt;Caleb&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 03 Sep 2019 15:36:32 GMT</pubDate>
    <dc:creator>CalebPourchot</dc:creator>
    <dc:date>2019-09-03T15:36:32Z</dc:date>
    <item>
      <title>100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174082#M1989</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I upgraded to 100.6 for Forms. With no other changes I started crashing when displaying the map because I set LocationDisplay.Enabled to true. However, LocationDisplay is now always null. This is on both Android and iOS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;on iOS, I have Always Enabled location permissions on and they are working because I am getting location updates.&amp;nbsp;&lt;/P&gt;&lt;P&gt;on Android, I have location permissions on as well and they are working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please advise,&lt;/P&gt;&lt;P&gt;Caleb&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Sep 2019 15:36:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174082#M1989</guid>
      <dc:creator>CalebPourchot</dc:creator>
      <dc:date>2019-09-03T15:36:32Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174083#M1990</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Caleb! Thanks for asking about this issue. This is due to a behavior change in 100.6. You must wait for the LocationDisplay of your MapView to load before enabling it and changing it's properties. You can add an event handler for the PropertyChanged event in your MapView to enable your location display&amp;nbsp;once it is loaded.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;MyMapView&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;PropertyChanged &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;o&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; e&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
    &lt;SPAN class="keyword token"&gt;if&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;e&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;PropertyName &lt;SPAN class="operator token"&gt;==&lt;/SPAN&gt; &lt;SPAN class="token function"&gt;nameof&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;MyMapView&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;LocationDisplay&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;&amp;amp;&amp;amp;&lt;/SPAN&gt; MyMapView&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;LocationDisplay &lt;SPAN class="operator token"&gt;!=&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;null&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
    &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
        &lt;SPAN class="comment token"&gt;// Enable your location display.&lt;/SPAN&gt;
        MyMapView&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;LocationDisplay&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;IsEnabled &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;true&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;
    &lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;
&lt;SPAN class="punctuation token"&gt;}&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;We use this pattern in our &lt;A href="https://github.com/Esri/arcgis-runtime-samples-dotnet/blob/master/src/Forms/Shared/Samples/Location/ShowLocationHistory/ShowLocationHistory.xaml.cs" rel="nofollow noopener noreferrer" target="_blank"&gt;Show location history sample&lt;/A&gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope that this helps,&lt;/P&gt;&lt;P&gt;Zack&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 08:59:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174083#M1990</guid>
      <dc:creator>ZackAllen</dc:creator>
      <dc:date>2021-12-11T08:59:56Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174084#M1991</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Zack,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I appreciate this info. It would've been great if changes like these were&lt;/P&gt;&lt;P&gt;well noted in the release notes. If I missed it, I apologize.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;All the best,&lt;/P&gt;&lt;P&gt;Caleb&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Sep 2019 16:37:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174084#M1991</guid>
      <dc:creator>CalebPourchot</dc:creator>
      <dc:date>2019-09-03T16:37:02Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174085#M1992</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A slightly different/simpler approach is just to wait for the Page.OnAppearing event to fire. This event ensures the Xamarin.Forms renderers are correctly hooked up to the native underlying view. Generally I'd recommend to wait with doing too much to the MapView until this event fires.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Currently LocationDisplay isn't settable, which prevents us from linking it to the native view until that link has been established (we're hoping to make it settable so this specific change in behavior could go away). It was, believe it or not, a bug that there was an underlying native view prior to the appearing event, which caused a slew of life-cycle issues. that we now addressed in Update 6. Unfortunately you might see a couple of these behavioral changes due to us fixing this problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good feedback that we should have documented this change in behavior. We'll try and get that addressed.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Sep 2019 17:57:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174085#M1992</guid>
      <dc:creator>dotMorten_esri</dc:creator>
      <dc:date>2019-09-03T17:57:04Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174086#M1993</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I had it attached to the Map.MapLoaded event, so apparently that fires&lt;/P&gt;&lt;P&gt;before Page.OnAppearing. Is this guaranteed? Are there things that&lt;/P&gt;&lt;P&gt;shouldn't be touched if OnAppearing has fired, but the map isn't quite&lt;/P&gt;&lt;P&gt;loaded?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Caleb&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 03 Sep 2019 18:11:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174086#M1993</guid>
      <dc:creator>CalebPourchot</dc:creator>
      <dc:date>2019-09-03T18:11:14Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174087#M1994</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;It should be. I haven't seen a case where the underlying Forms renderers aren't hooked up at that point.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Sep 2019 16:11:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174087#M1994</guid>
      <dc:creator>dotMorten_esri</dc:creator>
      <dc:date>2019-09-05T16:11:34Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174088#M1995</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This just hit me as well - I did not see anything in the release notes. Going to have to change a few things around to get this working again.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mike...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 16 Sep 2019 21:10:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174088#M1995</guid>
      <dc:creator>MichaelHamsa</dc:creator>
      <dc:date>2019-09-16T21:10:12Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174089#M1996</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I recently switched to Page Appearing strategy and it is occasionally crashing - so far only on Android:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL class="" style="color: #000000; background-color: rgba(0, 0, 0, 0.04); font-size: 14px;"&gt;&lt;LI class="" data-test-class="stack-frame" style="color: rgba(0, 0, 0, 0.3);"&gt;&lt;DIV class="" data-test-class="stack-frame-content" style="color: var(--secondary-text); font-size: 12px; padding-left: 5px;"&gt;&lt;SPAN&gt;&lt;SPAN class="" data-highlight="className" style="color: var(--code-class-name);"&gt;MapViewGenericViewModel&lt;/SPAN&gt;.&lt;SPAN class="" data-highlight="method" style="color: var(--code-method);"&gt;InitializeLocationDisplay&lt;/SPAN&gt;&amp;nbsp;()&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI class="" data-test-class="stack-frame" style="color: rgba(0, 0, 0, 0.3);"&gt;&lt;DIV class="" data-test-class="stack-frame-content" style="color: var(--secondary-text); font-size: 12px; padding-left: 5px;"&gt;&lt;SPAN&gt;&lt;SPAN class="" data-highlight="className" style="color: var(--code-class-name);"&gt;MapViewGenericViewModel&lt;/SPAN&gt;.&lt;SPAN class="" data-highlight="method" style="color: var(--code-method);"&gt;PageAppearing&lt;/SPAN&gt;&amp;nbsp;()&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI class="" data-test-class="stack-frame" style="color: rgba(0, 0, 0, 0.3);"&gt;&lt;DIV class="" data-test-class="stack-frame-content" style="color: var(--secondary-text); font-size: 12px; padding-left: 5px;"&gt;&lt;SPAN&gt;&lt;SPAN class="" data-highlight="className" style="color: var(--code-class-name);"&gt;AsyncMethodBuilderCore+&amp;lt;&amp;gt;c&lt;/SPAN&gt;.&lt;SPAN class="" data-highlight="method" style="color: var(--code-method);"&gt;&amp;lt;ThrowAsync&amp;gt;b__7_0&lt;/SPAN&gt;&amp;nbsp;(&lt;SPAN class="" data-highlight="methodParams" style="color: var(--code-method-params);"&gt;System.Object state&lt;/SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI class="" data-test-class="stack-frame" style="color: rgba(0, 0, 0, 0.3);"&gt;&lt;DIV class="" data-test-class="stack-frame-content" style="color: var(--secondary-text); font-size: 12px; padding-left: 5px;"&gt;&lt;SPAN&gt;&lt;SPAN class="" data-highlight="className" style="color: var(--code-class-name);"&gt;SyncContext+&amp;lt;&amp;gt;c__DisplayClass2_0&lt;/SPAN&gt;.&lt;SPAN class="" data-highlight="method" style="color: var(--code-method);"&gt;&amp;lt;Post&amp;gt;b__0&lt;/SPAN&gt;&amp;nbsp;()&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI class="" data-test-class="stack-frame" style="color: rgba(0, 0, 0, 0.3);"&gt;&lt;DIV class="" data-test-class="stack-frame-content" style="color: var(--secondary-text); font-size: 12px; padding-left: 5px;"&gt;&lt;SPAN&gt;&lt;SPAN class="" data-highlight="className" style="color: var(--code-class-name);"&gt;Thread+RunnableImplementor&lt;/SPAN&gt;.&lt;SPAN class="" data-highlight="method" style="color: var(--code-method);"&gt;Run&lt;/SPAN&gt;&amp;nbsp;()&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI class="" data-test-class="stack-frame" style="color: rgba(0, 0, 0, 0.3);"&gt;&lt;DIV class="" data-test-class="stack-frame-content" style="color: var(--secondary-text); font-size: 12px; padding-left: 5px;"&gt;&lt;SPAN&gt;&lt;SPAN class="" data-highlight="className" style="color: var(--code-class-name);"&gt;IRunnableInvoker&lt;/SPAN&gt;.&lt;SPAN class="" data-highlight="method" style="color: var(--code-method);"&gt;n_Run&lt;/SPAN&gt;&amp;nbsp;(&lt;SPAN class="" data-highlight="methodParams" style="color: var(--code-method-params);"&gt;System.IntPtr jnienv, System.IntPtr native__this&lt;/SPAN&gt;)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;LI class="" data-test-class="stack-frame" style="color: rgba(0, 0, 0, 0.3);"&gt;&lt;DIV class="" data-test-class="stack-frame-content" style="color: var(--secondary-text); font-size: 12px; padding-left: 5px;"&gt;&lt;SPAN&gt;(wrapper dynamic-method) Android.Runtime.DynamicMethodNameCounter.63(intptr,intptr)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Null reference exception when trying to enable location display in my Page Appearing handler. I have to switch back to the original propertychanged method given above. This also makes me nervous about other things that aren't ready during Page Appearing...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Caleb&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 05 Nov 2019 15:01:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/174089#M1996</guid>
      <dc:creator>CalebPourchot</dc:creator>
      <dc:date>2019-11-05T15:01:39Z</dc:date>
    </item>
    <item>
      <title>Re: 100.6 LocationDisplay always null</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/1079059#M10273</link>
      <description>&lt;P&gt;Hello guys,&lt;/P&gt;&lt;P&gt;I know that this is an old topic, but I'm trying to implement the functionalities of the MapView using the MVVM and even for the version 100.11, the LocationDisplay is returning null.&lt;/P&gt;&lt;P&gt;I would like to know if this issue was already fixed.&lt;/P&gt;&lt;P&gt;if so, could somebody provide some documentation/code snippet in how to initialize correctly the MapView base on MVVM implementation.&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Marcio&lt;/P&gt;</description>
      <pubDate>Thu, 15 Jul 2021 02:53:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/100-6-locationdisplay-always-null/m-p/1079059#M10273</guid>
      <dc:creator>msilvatavares</dc:creator>
      <dc:date>2021-07-15T02:53:28Z</dc:date>
    </item>
  </channel>
</rss>

