<?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: Getting sub layers from ArcGISDynamicMapservice in ArcGIS API for Silverlight Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/getting-sub-layers-from-arcgisdynamicmapservice/m-p/411589#M10680</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think I have found a solution to my problem. I am using the following to get details of a feature layer from ArcGISDynamicServiceMapLayer and applying the required query definition to it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ArcGISDynamicMapServiceLayer dynamicLayer=myMap.Layers["myDynamicLayer"] as ArcGISDynamicMapServiceLayer;&lt;/P&gt;&lt;P&gt;string query="";&lt;/P&gt;&lt;P&gt;dynamicLayer.GetDetails(layerID,(ESRI.ArcGIS.Client.FeatuerService.FeatureLayerInfo myFeatureLayer,Exception ex) =&amp;gt; {&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;if(ex == null)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; query=myFeatureLayer.DefinitionExpression;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;System.Collections.ObjectModel.ObservableCollection&amp;lt;LayerDefination&amp;gt; definitionCollection = new &amp;nbsp; &amp;nbsp; &amp;nbsp;System.Collections.ObjectModel.ObservableCollection&amp;lt;LayerDefination&amp;gt;();&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; LayerDefinition layerDef=new LayerDefinition();&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; layerDef.ID=layerID;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;layerDef.Definition=query+" AND Count &amp;gt; 100";&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;definitionCollection.Add(layerDef);&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;dynamicLayer.LayerDefinitions=definitionCollection;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;dynamicLayer.Refresh();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Source:&amp;nbsp;&lt;A href="https://developers.arcgis.com/silverlight/api-reference/ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.ArcGISDynamicMapServiceLayer~GetDetails.html"&gt;silverlight api reference&lt;/A&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 04 Nov 2016 06:19:20 GMT</pubDate>
    <dc:creator>Abdul_Raheem</dc:creator>
    <dc:date>2016-11-04T06:19:20Z</dc:date>
    <item>
      <title>Getting sub layers from ArcGISDynamicMapservice</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/getting-sub-layers-from-arcgisdynamicmapservice/m-p/411588#M10679</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a rest service url which I have used to create dynamic service and added it to the map. I want to loop through the arcgis dynamic map service layer to access feature layers in it.Is there any way to access feature layers in arcgis dynamic layer ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Oct 2016 12:09:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/getting-sub-layers-from-arcgisdynamicmapservice/m-p/411588#M10679</guid>
      <dc:creator>Abdul_Raheem</dc:creator>
      <dc:date>2016-10-18T12:09:32Z</dc:date>
    </item>
    <item>
      <title>Re: Getting sub layers from ArcGISDynamicMapservice</title>
      <link>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/getting-sub-layers-from-arcgisdynamicmapservice/m-p/411589#M10680</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think I have found a solution to my problem. I am using the following to get details of a feature layer from ArcGISDynamicServiceMapLayer and applying the required query definition to it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ArcGISDynamicMapServiceLayer dynamicLayer=myMap.Layers["myDynamicLayer"] as ArcGISDynamicMapServiceLayer;&lt;/P&gt;&lt;P&gt;string query="";&lt;/P&gt;&lt;P&gt;dynamicLayer.GetDetails(layerID,(ESRI.ArcGIS.Client.FeatuerService.FeatureLayerInfo myFeatureLayer,Exception ex) =&amp;gt; {&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;if(ex == null)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; query=myFeatureLayer.DefinitionExpression;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;System.Collections.ObjectModel.ObservableCollection&amp;lt;LayerDefination&amp;gt; definitionCollection = new &amp;nbsp; &amp;nbsp; &amp;nbsp;System.Collections.ObjectModel.ObservableCollection&amp;lt;LayerDefination&amp;gt;();&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; LayerDefinition layerDef=new LayerDefinition();&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; layerDef.ID=layerID;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;layerDef.Definition=query+" AND Count &amp;gt; 100";&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;definitionCollection.Add(layerDef);&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;dynamicLayer.LayerDefinitions=definitionCollection;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;dynamicLayer.Refresh();&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Source:&amp;nbsp;&lt;A href="https://developers.arcgis.com/silverlight/api-reference/ESRI.ArcGIS.Client~ESRI.ArcGIS.Client.ArcGISDynamicMapServiceLayer~GetDetails.html"&gt;silverlight api reference&lt;/A&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 04 Nov 2016 06:19:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-silverlight-questions/getting-sub-layers-from-arcgisdynamicmapservice/m-p/411589#M10680</guid>
      <dc:creator>Abdul_Raheem</dc:creator>
      <dc:date>2016-11-04T06:19:20Z</dc:date>
    </item>
  </channel>
</rss>

