<?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 determine spatial reference of ArcGISLocalTiledLayer in .NET Maps SDK Questions</title>
    <link>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395498#M4667</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;To get the errors, you have to subscribe to the MapView event 'LayerLoaded'.&lt;/P&gt;&lt;P&gt;In the event handler, the 'LoadError' gives you the error that happened when trying to load the layer into the view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, you are right that the DefaultSpatialReference of the local layer is not initialized.&lt;/P&gt;&lt;P&gt;We'll try to fix that in a future release.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thansk for reporting this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 14 Oct 2014 07:45:07 GMT</pubDate>
    <dc:creator>DominiqueBroux</dc:creator>
    <dc:date>2014-10-14T07:45:07Z</dc:date>
    <item>
      <title>How to determine spatial reference of ArcGISLocalTiledLayer</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395497#M4666</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have noticed that if I add an ArcGISLocalTileLayer from a different spatial reference than the other layers in the map, I don't get an on the fly reprojection. This is fine, but I need a way to detect the conflict. How can I determine the spatial reference of this type of layer. I see a DefaultSpatialReference property that looked promising, but it is null after the layer is initialized. The layer adds to the map without any error or indication of this issue. I need a way to detect this so that I can notify the user.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Oct 2014 15:07:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395497#M4666</guid>
      <dc:creator>LukePatterson</dc:creator>
      <dc:date>2014-10-12T15:07:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to determine spatial reference of ArcGISLocalTiledLayer</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395498#M4667</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;To get the errors, you have to subscribe to the MapView event 'LayerLoaded'.&lt;/P&gt;&lt;P&gt;In the event handler, the 'LoadError' gives you the error that happened when trying to load the layer into the view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, you are right that the DefaultSpatialReference of the local layer is not initialized.&lt;/P&gt;&lt;P&gt;We'll try to fix that in a future release.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thansk for reporting this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Oct 2014 07:45:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395498#M4667</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2014-10-14T07:45:07Z</dc:date>
    </item>
    <item>
      <title>Re: How to determine spatial reference of ArcGISLocalTiledLayer</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395499#M4668</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Having the DefaultSpatialReference fix would be useful! I have a need to determine the spatial reference prior to adding a layer to my map. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The error shown in the LayerLoaded event is definitely useful for notifying users of a spatial reference conflict after the layer has been added.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I did find a way to determine the spatial reference of ArcGISLocalTiledLayer prior to adding to my map. &lt;EM&gt;Disclaimer: This is a very ugly approach that involves a dummy map&lt;/EM&gt; &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ArcGISLocalTiledLayer tiledLayer = new ArcGISLocalTiledLayer(layerDataSource.Path);&lt;/P&gt;&lt;P&gt;await tiledLayer.InitializeAsync();&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 1.5;"&gt;SpatialReference tiledSpatial;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 1.5;"&gt;var tempView = new MapView();&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="line-height: 1.5;"&gt;tempView.Map.Layers.Add(tiledLayer);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;tempView.Visibility = Visibility.Hidden;&lt;/P&gt;&lt;P&gt;mapGrid.Children.Add(tempView); //add invisible map&lt;/P&gt;&lt;P&gt;await tempView.ZoomAsync(0);&lt;/P&gt;&lt;P&gt;tiledSpatial = tempView.SpatialReference;&lt;/P&gt;&lt;P&gt;mapGrid.Children.Remove(tempView); //remove invisible map&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Oct 2014 02:30:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395499#M4668</guid>
      <dc:creator>LukePatterson</dc:creator>
      <dc:date>2014-10-15T02:30:26Z</dc:date>
    </item>
    <item>
      <title>Re: How to determine spatial reference of ArcGISLocalTiledLayer</title>
      <link>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395500#M4669</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nice workaround. Thanks for sharing it.&lt;/P&gt;&lt;P&gt;It's definitively a fix that is in the list for the next version.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Oct 2014 08:28:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/net-maps-sdk-questions/how-to-determine-spatial-reference-of/m-p/395500#M4669</guid>
      <dc:creator>DominiqueBroux</dc:creator>
      <dc:date>2014-10-15T08:28:38Z</dc:date>
    </item>
  </channel>
</rss>

