<?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 Map from URL not loading despite working with URL of same format from the examples (ArcGIS macOS SDK) in Developers Questions</title>
    <link>https://community.esri.com/t5/developers-questions/map-from-url-not-loading-despite-working-with-url/m-p/663936#M4537</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm trying to load OpenStreetMap into a program I'm writing in Swift, using the ArcGIS SDK for macOS. I have the loading of built in maps (theMap.map = AGSMap(basemap: AGSBasemap.imagery())) working but I cannot seem to load OpenStreetMap from its URL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the URL I am using:&amp;nbsp;&lt;A href="https://www.arcgis.com/home/item.html?id=b834a68d7a484c5fb473d4ba90d35e71" rel="nofollow noreferrer"&gt;https://www.arcgis.com/home/item.html?id=b834a68d7a484c5fb473d4ba90d35e71&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I am using the following code to load the URL, taken from the ArcGIS Examples:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;let openStreetMap = "&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2Fwww.arcgis.com%2Fhome%2Fitem.html%3Fid%3Db834a68d7a484c5fb473d4ba90d35e71" rel="nofollow" target="_blank"&gt;https://www.arcgis.com/home/item.html?id=b834a68d7a484c5fb473d4ba90d35e71&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;let tiles = AGSArcGISVectorTiledLayer(url: URL(string: openStreetMap)!)&lt;/P&gt;&lt;P&gt;theMap.map = AGSMap(basemap: AGSBasemap(baseLayer: tiles))&lt;/P&gt;&lt;P style="color: #000000; font-size: 11px;"&gt;&lt;/P&gt;&lt;P&gt;The map does not load and all I end up with is a grey gridded background. Surprisingly, if I swap the URL with one I found in the ArcGIS examples (&lt;A href="https://www.arcgis.com/home/item.html?id=4e1133c28ac04cca97693cf336cd49ad" rel="nofollow noreferrer"&gt;https://www.arcgis.com/home/item.html?id=4e1133c28ac04cca97693cf336cd49ad&lt;/A&gt;), that map loads with no problems. The two URLs are in exactly the same format but only one works. Why is this and how can I get it to load the OpenStreetMap URL? Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 23 Feb 2017 11:26:01 GMT</pubDate>
    <dc:creator>HenryHunt1</dc:creator>
    <dc:date>2017-02-23T11:26:01Z</dc:date>
    <item>
      <title>Map from URL not loading despite working with URL of same format from the examples (ArcGIS macOS SDK)</title>
      <link>https://community.esri.com/t5/developers-questions/map-from-url-not-loading-despite-working-with-url/m-p/663936#M4537</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm trying to load OpenStreetMap into a program I'm writing in Swift, using the ArcGIS SDK for macOS. I have the loading of built in maps (theMap.map = AGSMap(basemap: AGSBasemap.imagery())) working but I cannot seem to load OpenStreetMap from its URL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is the URL I am using:&amp;nbsp;&lt;A href="https://www.arcgis.com/home/item.html?id=b834a68d7a484c5fb473d4ba90d35e71" rel="nofollow noreferrer"&gt;https://www.arcgis.com/home/item.html?id=b834a68d7a484c5fb473d4ba90d35e71&lt;/A&gt;&lt;/P&gt;&lt;P&gt;I am using the following code to load the URL, taken from the ArcGIS Examples:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;let openStreetMap = "&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2Fwww.arcgis.com%2Fhome%2Fitem.html%3Fid%3Db834a68d7a484c5fb473d4ba90d35e71" rel="nofollow" target="_blank"&gt;https://www.arcgis.com/home/item.html?id=b834a68d7a484c5fb473d4ba90d35e71&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;let tiles = AGSArcGISVectorTiledLayer(url: URL(string: openStreetMap)!)&lt;/P&gt;&lt;P&gt;theMap.map = AGSMap(basemap: AGSBasemap(baseLayer: tiles))&lt;/P&gt;&lt;P style="color: #000000; font-size: 11px;"&gt;&lt;/P&gt;&lt;P&gt;The map does not load and all I end up with is a grey gridded background. Surprisingly, if I swap the URL with one I found in the ArcGIS examples (&lt;A href="https://www.arcgis.com/home/item.html?id=4e1133c28ac04cca97693cf336cd49ad" rel="nofollow noreferrer"&gt;https://www.arcgis.com/home/item.html?id=4e1133c28ac04cca97693cf336cd49ad&lt;/A&gt;), that map loads with no problems. The two URLs are in exactly the same format but only one works. Why is this and how can I get it to load the OpenStreetMap URL? Thanks.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Feb 2017 11:26:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/map-from-url-not-loading-despite-working-with-url/m-p/663936#M4537</guid>
      <dc:creator>HenryHunt1</dc:creator>
      <dc:date>2017-02-23T11:26:01Z</dc:date>
    </item>
  </channel>
</rss>

