<?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 do I switch BaseLayers or why does a WMSLayer prevent my other layers to show in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/how-do-i-switch-baselayers-or-why-does-a-wmslayer/m-p/652003#M14497</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Steve,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Normally a ArcGISTiledMapServiceLayer is used as the first layer in the map so that it sets the maps LODs (levels of Display) I you are going to add an ArcGISTiledMapServiceLayer at a later point than you need to manually specify the Maps LODs and they will need to be the same (or partially the same) as the ArcGISTiledMapServiceLayer you intend to add. You also need to be concerned with the WKID of all your map layers as the ArcGISTiledMapServiceLayer&amp;nbsp; will not get re-projected to match your WMSLayer.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 22 Feb 2013 02:13:20 GMT</pubDate>
    <dc:creator>RobertScheitlin__GISP</dc:creator>
    <dc:date>2013-02-22T02:13:20Z</dc:date>
    <item>
      <title>How do I switch BaseLayers or why does a WMSLayer prevent my other layers to show?</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/how-do-i-switch-baselayers-or-why-does-a-wmslayer/m-p/652002#M14496</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I've got a WMSLayer as the first layer in a map, and I'm adding a ArcGISTiledMapServiceLayer to the map, but whereever I put it, at index 0 or index 1, it won't show???&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Do I need to switch the baselayer?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;here's the code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;&amp;lt;?xml version="1.0" encoding="utf-8"?&amp;gt;
&amp;lt;s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; xmlns:s="library://ns.adobe.com/flex/spark"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; xmlns:esri="http://www.esri.com/2008/ags"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pageTitle="World Imagery Map"&amp;gt;
 &amp;lt;fx:Script&amp;gt;
&amp;nbsp; &amp;lt;![CDATA[
&amp;nbsp;&amp;nbsp; import com.esri.ags.layers.ArcGISTiledMapServiceLayer;
&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; protected function button1_clickHandler(event:MouseEvent):void
&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp; var url:String = "http://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer";
&amp;nbsp;&amp;nbsp;&amp;nbsp; var tiledMapLayer:ArcGISTiledMapServiceLayer = new ArcGISTiledMapServiceLayer( url);
&amp;nbsp;&amp;nbsp;&amp;nbsp; mymap.addLayer(tiledMapLayer&amp;nbsp; );&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; }
&amp;nbsp; ]]&amp;gt;
 &amp;lt;/fx:Script&amp;gt;
 &amp;lt;esri:Map id="mymap" wrapAround180="true"&amp;gt;
&amp;nbsp; &amp;lt;esri:WMSLayer&amp;nbsp; id="amIaBug"&amp;nbsp; visible="false" /&amp;gt;
&amp;nbsp; &amp;lt;!--&amp;lt;esri:ArcGISTiledMapServiceLayer url="http://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer"/&amp;gt;--&amp;gt;
 &amp;lt;/esri:Map&amp;gt;
 &amp;lt;s:Button top="50" left="100" label="add Layer" click="button1_clickHandler(event)" /&amp;gt;
&amp;lt;/s:Application&amp;gt;&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have a map with a WMSLayer, when I click the button - it adds a tiledMapServiceLayer, but it doesn't show, try adding it before or after the WMSLayer and it still doesn't show.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Comment out the WMSLayer and the Tiledlayer shows fine.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;How do I get it to show?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;thanks,&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Feb 2013 01:17:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/how-do-i-switch-baselayers-or-why-does-a-wmslayer/m-p/652002#M14496</guid>
      <dc:creator>stevemclaughlin</dc:creator>
      <dc:date>2013-02-22T01:17:26Z</dc:date>
    </item>
    <item>
      <title>Re: How do I switch BaseLayers or why does a WMSLayer prevent my other layers to show</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/how-do-i-switch-baselayers-or-why-does-a-wmslayer/m-p/652003#M14497</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Steve,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Normally a ArcGISTiledMapServiceLayer is used as the first layer in the map so that it sets the maps LODs (levels of Display) I you are going to add an ArcGISTiledMapServiceLayer at a later point than you need to manually specify the Maps LODs and they will need to be the same (or partially the same) as the ArcGISTiledMapServiceLayer you intend to add. You also need to be concerned with the WKID of all your map layers as the ArcGISTiledMapServiceLayer&amp;nbsp; will not get re-projected to match your WMSLayer.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Feb 2013 02:13:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/how-do-i-switch-baselayers-or-why-does-a-wmslayer/m-p/652003#M14497</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2013-02-22T02:13:20Z</dc:date>
    </item>
    <item>
      <title>Re: How do I switch BaseLayers or why does a WMSLayer prevent my other layers to show</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/how-do-i-switch-baselayers-or-why-does-a-wmslayer/m-p/652004#M14498</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi, I just created a blank baselayer and will load it later when I know the url.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ex:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;exri:Map id='myMap'/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;esri:ArcGisTiledMapServiceLayer id='baselayer' /&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;lt;exri:WMSLayer url='&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://myweb.com/map.cgi" rel="nofollow" target="_blank"&gt;http://myweb.com/map.cgi&lt;/A&gt;&lt;SPAN&gt;' /&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;then later in my code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;baselayer.url = '&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://server.arcgisonline.com/blah/blah/mapserver';" rel="nofollow" target="_blank"&gt;http://server.arcgisonline.com/blah/blah/mapserver';&lt;/A&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This seems to be working fine for me, do you see any side effects that may come up?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Feb 2013 20:53:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/how-do-i-switch-baselayers-or-why-does-a-wmslayer/m-p/652004#M14498</guid>
      <dc:creator>stevemclaughlin</dc:creator>
      <dc:date>2013-02-22T20:53:15Z</dc:date>
    </item>
  </channel>
</rss>

