<?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 Re: how to show current location on arcgis map in android? in ArcGIS Runtime SDK for Android Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-to-show-current-location-on-arcgis-map-in/m-p/744246#M5234</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Your description of the problem is somewhat vague... do you mean you want to be able to use device GPS to locate yourself on map? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You need to use LocationDisplayManager - here is some code from my app&lt;/P&gt;&lt;P&gt;// In case you need it later, make it class variable&lt;/P&gt;&lt;P&gt;LocationDisplayManager &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;lDisplayManager &lt;/SPAN&gt;= &lt;SPAN style="color: #000080; font-weight: bold;"&gt;null&lt;/SPAN&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// ... inside onCreate(), after your .addlayers&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.setOnStatusChangedListener(&lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;OnStatusChangedListener() {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808080; font-style: italic;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onStatusChanged(Object source, STATUS status) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;if &lt;/SPAN&gt;(source == &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView &lt;/SPAN&gt;&amp;amp;&amp;amp; status == STATUS.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;INITIALIZED&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt; &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5; color: #660e7a; font-weight: bold;"&gt;lDisplayManager &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;= &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5; color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;.getLocationDisplayManager();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;lDisplayManager&lt;/SPAN&gt;.setAutoPanMode(LocationDisplayManager.AutoPanMode.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;LOCATION&lt;/SPAN&gt;);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;lDisplayManager&lt;/SPAN&gt;.setLocationListener(&lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;LocationListener() {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;boolean &lt;/SPAN&gt;&lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;locationChanged &lt;/SPAN&gt;= &lt;SPAN style="color: #000080; font-weight: bold;"&gt;false&lt;/SPAN&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808080; font-style: italic;"&gt;// Zooms to the current location when first GPS fix arrives. &lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onLocationChanged(Location loc) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;if &lt;/SPAN&gt;(!&lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;locationChanged&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;locationChanged &lt;/SPAN&gt;= &lt;SPAN style="color: #000080; font-weight: bold;"&gt;true&lt;/SPAN&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;double &lt;/SPAN&gt;locy = loc.getLatitude();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;double &lt;/SPAN&gt;locx = loc.getLongitude();&lt;/P&gt;&lt;P&gt;&amp;nbsp; Point wgspoint = &lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;Point(locx, locy);&lt;/P&gt;&lt;P&gt;&amp;nbsp; Point mapPoint = (Point) GeometryEngine&lt;/P&gt;&lt;P&gt;&amp;nbsp; .&lt;SPAN style="font-style: italic;"&gt;project&lt;/SPAN&gt;(wgspoint,&lt;/P&gt;&lt;P&gt;&amp;nbsp; SpatialReference.&lt;SPAN style="font-style: italic;"&gt;create&lt;/SPAN&gt;(&lt;SPAN style="color: #0000ff;"&gt;4326&lt;/SPAN&gt;),&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.getSpatialReference());&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Unit mapUnit = &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.getSpatialReference()&lt;/P&gt;&lt;P&gt;&amp;nbsp; .getUnit();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;double &lt;/SPAN&gt;zoomWidth = Unit.&lt;SPAN style="font-style: italic;"&gt;convertUnits&lt;/SPAN&gt;(&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; 5,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Unit.&lt;SPAN style="font-style: italic;"&gt;create&lt;/SPAN&gt;(LinearUnit.Code.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;MILE_US&lt;/SPAN&gt;),&lt;/P&gt;&lt;P&gt;&amp;nbsp; mapUnit);&lt;/P&gt;&lt;P&gt;&amp;nbsp; Envelope zoomExtent = &lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;Envelope(mapPoint,&lt;/P&gt;&lt;P&gt;&amp;nbsp; zoomWidth, zoomWidth);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.setExtent(zoomExtent);&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onProviderDisabled(String arg0) {&lt;/P&gt;&lt;P&gt; &lt;SPAN style="line-height: 1.5;"&gt; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onProviderEnabled(String arg0) {&lt;/P&gt;&lt;P&gt; &lt;SPAN style="line-height: 1.5;"&gt; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onStatusChanged(String arg0, &lt;SPAN style="color: #000080; font-weight: bold;"&gt;int &lt;/SPAN&gt;arg1,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Bundle arg2) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; });&amp;nbsp; &lt;SPAN style="color: #808080; font-style: italic;"&gt;// Actionlistener&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5; color: #660e7a; font-weight: bold;"&gt;lDisplayManager&lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;.start();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;if &lt;/SPAN&gt;(source == &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView &lt;/SPAN&gt;&amp;amp;&amp;amp; status == STATUS.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;LAYER_LOADED&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;});&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There might be some extra } or { as I copy pasted it from the code and had to remove some special stuff related to our app.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Jun 2015 04:45:20 GMT</pubDate>
    <dc:creator>TeroRönkkö</dc:creator>
    <dc:date>2015-06-26T04:45:20Z</dc:date>
    <item>
      <title>how to show current location on arcgis map in android?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-to-show-current-location-on-arcgis-map-in/m-p/744245#M5233</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Guys&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am new bee to ArcGis. I am developing ArcGis map in my Android app. may is displayed using one url in ArcGISTiledMapServiceLayer&lt;/P&gt;&lt;P&gt;this is my code fragment----&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;setContentView&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;R&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;layout&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit;"&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;main&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;);&lt;/SPAN&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp; mMapView &lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;=&lt;/SPAN&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt; &lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="typ" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #660066;"&gt;MapView&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;)&lt;/SPAN&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt; findViewById&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;(&lt;/SPAN&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;R&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;id&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;.&lt;/SPAN&gt;&lt;SPAN style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit;"&gt;&lt;SPAN class="pln" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;map&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="pun" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #555555;"&gt;);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #555555;"&gt;mMapView&lt;/SPAN&gt;.addLayer(new ArcGISTiledMapServiceLayer(&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp; "&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://maps.ocparks.com/arcgis/rest/services/Imagery/2013_Imagery/MapServer" rel="nofollow" target="_blank"&gt;http://maps.ocparks.com/arcgis/rest/services/Imagery/2013_Imagery/MapServer&lt;/A&gt;&lt;SPAN&gt;"));&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;along with this url I am using some other urls for adding layers on map in ArcGISFeatureLayer. All is working good. now&amp;nbsp; I want to show current location of device on this Map. after going through several tutorials and documentations I came to know that for displaying location we must use &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #555555;"&gt;mMapView&lt;/SPAN&gt;.addLayer(new ArcGISTiledMapServiceLayer(&lt;/P&gt;&lt;P&gt;&amp;nbsp; "&lt;/P&gt;&lt;P&gt;&lt;SPAN class="str" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #cf8b20;"&gt;&lt;A class="jive-link-external-small" href="http://services.arcgisonline.com/ArcGIS/rest/services/" rel="nofollow" target="_blank"&gt;http://services.arcgisonline.com/ArcGIS/rest/services/&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="str" style="font-family: inherit; font-size: inherit; font-style: inherit; font-weight: inherit; color: #cf8b20;"&gt;&amp;nbsp; World_Street_Map/MapServer&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;")); &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so guys if there is any possible way to locate device location on ArcGis Imagery map.(not world_Street_map)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 24 Jun 2015 19:47:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-to-show-current-location-on-arcgis-map-in/m-p/744245#M5233</guid>
      <dc:creator>kuldeepdwivedi</dc:creator>
      <dc:date>2015-06-24T19:47:44Z</dc:date>
    </item>
    <item>
      <title>Re: how to show current location on arcgis map in android?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-to-show-current-location-on-arcgis-map-in/m-p/744246#M5234</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Your description of the problem is somewhat vague... do you mean you want to be able to use device GPS to locate yourself on map? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You need to use LocationDisplayManager - here is some code from my app&lt;/P&gt;&lt;P&gt;// In case you need it later, make it class variable&lt;/P&gt;&lt;P&gt;LocationDisplayManager &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;lDisplayManager &lt;/SPAN&gt;= &lt;SPAN style="color: #000080; font-weight: bold;"&gt;null&lt;/SPAN&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;// ... inside onCreate(), after your .addlayers&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.setOnStatusChangedListener(&lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;OnStatusChangedListener() {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808080; font-style: italic;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onStatusChanged(Object source, STATUS status) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;if &lt;/SPAN&gt;(source == &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView &lt;/SPAN&gt;&amp;amp;&amp;amp; status == STATUS.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;INITIALIZED&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt; &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5; color: #660e7a; font-weight: bold;"&gt;lDisplayManager &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;= &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5; color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;.getLocationDisplayManager();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;lDisplayManager&lt;/SPAN&gt;.setAutoPanMode(LocationDisplayManager.AutoPanMode.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;LOCATION&lt;/SPAN&gt;);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;lDisplayManager&lt;/SPAN&gt;.setLocationListener(&lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;LocationListener() {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;boolean &lt;/SPAN&gt;&lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;locationChanged &lt;/SPAN&gt;= &lt;SPAN style="color: #000080; font-weight: bold;"&gt;false&lt;/SPAN&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808080; font-style: italic;"&gt;// Zooms to the current location when first GPS fix arrives. &lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onLocationChanged(Location loc) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;if &lt;/SPAN&gt;(!&lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;locationChanged&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-weight: bold;"&gt;locationChanged &lt;/SPAN&gt;= &lt;SPAN style="color: #000080; font-weight: bold;"&gt;true&lt;/SPAN&gt;;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;double &lt;/SPAN&gt;locy = loc.getLatitude();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;double &lt;/SPAN&gt;locx = loc.getLongitude();&lt;/P&gt;&lt;P&gt;&amp;nbsp; Point wgspoint = &lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;Point(locx, locy);&lt;/P&gt;&lt;P&gt;&amp;nbsp; Point mapPoint = (Point) GeometryEngine&lt;/P&gt;&lt;P&gt;&amp;nbsp; .&lt;SPAN style="font-style: italic;"&gt;project&lt;/SPAN&gt;(wgspoint,&lt;/P&gt;&lt;P&gt;&amp;nbsp; SpatialReference.&lt;SPAN style="font-style: italic;"&gt;create&lt;/SPAN&gt;(&lt;SPAN style="color: #0000ff;"&gt;4326&lt;/SPAN&gt;),&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.getSpatialReference());&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Unit mapUnit = &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.getSpatialReference()&lt;/P&gt;&lt;P&gt;&amp;nbsp; .getUnit();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;double &lt;/SPAN&gt;zoomWidth = Unit.&lt;SPAN style="font-style: italic;"&gt;convertUnits&lt;/SPAN&gt;(&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; 5,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Unit.&lt;SPAN style="font-style: italic;"&gt;create&lt;/SPAN&gt;(LinearUnit.Code.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;MILE_US&lt;/SPAN&gt;),&lt;/P&gt;&lt;P&gt;&amp;nbsp; mapUnit);&lt;/P&gt;&lt;P&gt;&amp;nbsp; Envelope zoomExtent = &lt;SPAN style="color: #000080; font-weight: bold;"&gt;new &lt;/SPAN&gt;Envelope(mapPoint,&lt;/P&gt;&lt;P&gt;&amp;nbsp; zoomWidth, zoomWidth);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView&lt;/SPAN&gt;.setExtent(zoomExtent);&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onProviderDisabled(String arg0) {&lt;/P&gt;&lt;P&gt; &lt;SPAN style="line-height: 1.5;"&gt; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onProviderEnabled(String arg0) {&lt;/P&gt;&lt;P&gt; &lt;SPAN style="line-height: 1.5;"&gt; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #808000;"&gt;@Override&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808000;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="color: #000080; font-weight: bold;"&gt;public void &lt;/SPAN&gt;onStatusChanged(String arg0, &lt;SPAN style="color: #000080; font-weight: bold;"&gt;int &lt;/SPAN&gt;arg1,&lt;/P&gt;&lt;P&gt;&amp;nbsp; Bundle arg2) {&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; });&amp;nbsp; &lt;SPAN style="color: #808080; font-style: italic;"&gt;// Actionlistener&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #808080; font-style: italic;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5; color: #660e7a; font-weight: bold;"&gt;lDisplayManager&lt;/SPAN&gt;&lt;SPAN style="line-height: 1.5;"&gt;.start();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000080; font-weight: bold;"&gt;if &lt;/SPAN&gt;(source == &lt;SPAN style="color: #660e7a; font-style: italic;"&gt;mMapView &lt;/SPAN&gt;&amp;amp;&amp;amp; status == STATUS.&lt;SPAN style="color: #660e7a; font-weight: bold; font-style: italic;"&gt;LAYER_LOADED&lt;/SPAN&gt;) {&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 1.5;"&gt;&amp;nbsp; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;});&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There might be some extra } or { as I copy pasted it from the code and had to remove some special stuff related to our app.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Jun 2015 04:45:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-to-show-current-location-on-arcgis-map-in/m-p/744246#M5234</guid>
      <dc:creator>TeroRönkkö</dc:creator>
      <dc:date>2015-06-26T04:45:20Z</dc:date>
    </item>
    <item>
      <title>Re: how to show current location on arcgis map in android?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-to-show-current-location-on-arcgis-map-in/m-p/744247#M5235</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This code fragment only works with World_Street_Map server not with Imagery Map service&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Jun 2015 17:50:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-to-show-current-location-on-arcgis-map-in/m-p/744247#M5235</guid>
      <dc:creator>kuldeepdwivedi</dc:creator>
      <dc:date>2015-06-26T17:50:11Z</dc:date>
    </item>
  </channel>
</rss>

