<?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: Coercion Error with ESRI Flex Legend Component in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584328#M13122</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Sarthak,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thank you for the information; I have been away working on our migration plan to version 10 and just got back to this today.&amp;nbsp; I am not sure how to use the code you provided since the function you identified is not in any of the code I am working with, unless it is being brought in from the Reference Library. Again thank you for the information and if you can give me a little more guidance it would be greatly appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Greg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 25 Mar 2011 13:06:18 GMT</pubDate>
    <dc:creator>GregMcNeill</dc:creator>
    <dc:date>2011-03-25T13:06:18Z</dc:date>
    <item>
      <title>Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584323#M13117</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; I am in the process of combing the ESRI Dynamic Map Layers on/off Flex Sample and ESRI Legend Component Flex Sample into one application; however, I am getting a #1034: Type Coercion error when I toggle a layer.&amp;nbsp; When it comes to Flex programming I am a real novice or more of a hack, my background is SQL and VB, so please bear with me.&amp;nbsp; My interpretation of the error is that I am somehow generating a type miss-match between the data structure used for the Layers list and the structure used for the Legend display.&amp;nbsp; I thought both of these structures used an array that was populated by Dynamic Service, myDynamicService, therefore, I am very confused as to what is going on here.&amp;nbsp; I have attached a copy of my source files but here is the code for the Default mxml:&lt;/SPAN&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:mx="library://ns.adobe.com/flex/mx"
&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; xmlns:samples="com.*"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pageTitle="Layers and Legends"&amp;gt;

 &amp;lt;fx:Script&amp;gt;
&amp;nbsp; &amp;lt;![CDATA[
&amp;nbsp;&amp;nbsp; import mx.events.FlexEvent;
&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp; protected function application1_initializeHandler(event:FlexEvent):void
&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp; myLegend.layers = [ myDynamicService ];
&amp;nbsp;&amp;nbsp; }
&amp;nbsp; ]]&amp;gt;
 &amp;lt;/fx:Script&amp;gt;
 
 &amp;lt;s:layout&amp;gt;
&amp;nbsp; &amp;lt;s:VerticalLayout horizontalAlign="center"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; paddingBottom="20"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; paddingLeft="20"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; paddingRight="20"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; paddingTop="20"/&amp;gt;
 &amp;lt;/s:layout&amp;gt;
 
 &amp;lt;mx:HDividedBox width="100%" height="100%"&amp;gt;
&amp;nbsp; &amp;lt;esri:Map id="myMap"&amp;gt;
&amp;nbsp;&amp;nbsp; &amp;lt;esri:ArcGISDynamicMapServiceLayer id="myDynamicService" name=" "
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; load="myDynamicService.defaultVisibleLayers()"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; url="http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/Network/USA/MapServer"/&amp;gt;
&amp;nbsp; &amp;lt;/esri:Map&amp;gt;
&amp;nbsp; &amp;lt;mx:VBox width="40%" height="100%"&amp;gt;
&amp;nbsp;&amp;nbsp; &amp;lt;mx:Panel width="100%" height="50%" borderVisible="true" borderColor="#030303" title="Layers"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;samples:LayerTOC mapLayer="{myDynamicService}"/&amp;gt;
&amp;nbsp;&amp;nbsp; &amp;lt;/mx:Panel&amp;gt;
&amp;nbsp;&amp;nbsp; &amp;lt;mx:Panel width="100%" height="50%" borderVisible="true" borderColor="#030303" title="Legend"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;esri:Legend id="myLegend"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; width="100%" height="100%"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; map="{myMap}"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; respectCurrentMapScale="true"/&amp;gt;
&amp;nbsp;&amp;nbsp; &amp;lt;/mx:Panel&amp;gt;
&amp;nbsp; &amp;lt;/mx:VBox&amp;gt;
 &amp;lt;/mx:HDividedBox&amp;gt;
&amp;lt;/s:Application&amp;gt;&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;SPAN&gt;I hope someone can explain to me what is happening here to generate the Coercion error and hopefully help me resolve it so I can get the Legend to reflect what is displayed on the map.&amp;nbsp; Any help provided will be greatly appreciated, thank you.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;- Greg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Mar 2011 16:11:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584323#M13117</guid>
      <dc:creator>GregMcNeill</dc:creator>
      <dc:date>2011-03-02T16:11:43Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584324#M13118</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;What is the full text of the error?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Also, you don't need to set this if you want it to show all layers in the map:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;myLegend.layers = [ myDynamicService ];&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 02 Mar 2011 17:55:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584324#M13118</guid>
      <dc:creator>DasaPaddock</dc:creator>
      <dc:date>2011-03-02T17:55:06Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584325#M13119</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Dasa ,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thank you for the quick reply.&amp;nbsp; I dropped the myLegend.layers = [ myDynamicService ], it does make sense that I would have to call out the layers since it is already assigned to the Map object.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;After I submitted the initial post I noticed that the Legend is being updated in conjunction with the map as the layers are turned on and off once I clear the following error and zoom in or out just a little; panning will not update the layers.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;TypeError: Error #1034: Type Coercion failed: cannot convert mx.collections::ArrayCollection@87e04c1 to com.esri.ags.layers.ArcGISDynamicMapServiceLayer.
 at com.esri.ags.skins::LegendSkin/visibleLayersChangeHandler()&lt;C&gt;
 at flash.events::EventDispatcher/dispatchEventFunction()
 at flash.events::EventDispatcher/dispatchEvent()
 at mx.collections::ListCollectionView/dispatchEvent()&lt;E&gt;
 at mx.collections::ListCollectionView/removeItemsFromView()&lt;E&gt;
 at mx.collections::ListCollectionView/listChangeHandler()&lt;E&gt;
 at flash.events::EventDispatcher/dispatchEventFunction()
 at flash.events::EventDispatcher/dispatchEvent()
 at mx.collections::ArrayList/internalDispatchEvent()&lt;E&gt;
 at mx.collections::ArrayList/removeItemAt()&lt;E&gt;
 at mx.collections::ListCollectionView/removeItemAt()&lt;E&gt;
 at com::LayerTOC/hideLayer()&lt;C&gt;
 at com::LayerVizRenderer/cb_clickHandler()&lt;C&gt;
 at com::LayerVizRenderer/__cb_click()&lt;C&gt;&lt;/C&gt;&lt;/C&gt;&lt;/C&gt;&lt;/E&gt;&lt;/E&gt;&lt;/E&gt;&lt;/E&gt;&lt;/E&gt;&lt;/E&gt;&lt;/C&gt;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I now see that the application will function as I thought it would as soon as I figure out why I&amp;nbsp; am getting the above error and figure out how to resolve it from occurring.&amp;nbsp; Hopefully, the error message is more meaningful to you then it is to me, because I am under the impression I am not creating a type miss-match but obviously I must be wrong. I am open to any suggestions on how to resolve this issue, I appreciate your help.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Greg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:07:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584325#M13119</guid>
      <dc:creator>GregMcNeill</dc:creator>
      <dc:date>2021-12-12T01:07:20Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584326#M13120</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Greg,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've made a project that integrates the &lt;/SPAN&gt;&lt;A href="http://arcscripts.esri.com/details.asp?dbid=15874"&gt;TOC component&lt;/A&gt;&lt;SPAN&gt; that Tom Hill created for Flex 3 with the Legend component in a Flash Builder 4 project. As each layer is clicked on and offer, its legend is added or removed. As an added bonus, I have also included the code that will identify features in the visible layers and put them into a single InfoWindow, with the selected features of each layer listed in a datagrid on a separate tab.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The forum won't let me upload the project, but the screen shots give you an idea of what it does. Let me know if you'd like to see the project.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 03 Mar 2011 19:31:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584326#M13120</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2011-03-03T19:31:42Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584327#M13121</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hey Greg,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for reporting this. Turns out it is a bug in LegendSkin and will be fixed in the next version. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Actually, you can replace the "visibleLayersChangeHandler()" method in the skin you are using with:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
private function visibleLayersChangeHandler(event:CollectionEvent):void
{&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; const mapLayers:ArrayCollection = ArrayCollection(hostComponent.map.layers);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (var i:int = 0; i &amp;lt; mapLayers.length; )
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (mapLayers.getItemAt(i) is ArcGISDynamicMapServiceLayer &amp;amp;&amp;amp;
ArcGISDynamicMapServiceLayer(mapLayers.getItemAt(i)).visible &amp;amp;&amp;amp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ArcGISDynamicMapServiceLayer(mapLayers.getItemAt(i)).visibleLayers === event.target)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; visibleLayersChanged(ArcGISDynamicMapServiceLayer(mapLayers.getItemAt(i)));
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; break;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; i++;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
}
&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope that helps.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:07:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584327#M13121</guid>
      <dc:creator>SarthakDatt</dc:creator>
      <dc:date>2021-12-12T01:07:23Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584328#M13122</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Sarthak,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Thank you for the information; I have been away working on our migration plan to version 10 and just got back to this today.&amp;nbsp; I am not sure how to use the code you provided since the function you identified is not in any of the code I am working with, unless it is being brought in from the Reference Library. Again thank you for the information and if you can give me a little more guidance it would be greatly appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Greg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 Mar 2011 13:06:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584328#M13122</guid>
      <dc:creator>GregMcNeill</dc:creator>
      <dc:date>2011-03-25T13:06:18Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584329#M13123</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hey Greg,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Apologies for the late response. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This method is part of the LegendSkin class which is shipped out-of-the-box under the skins folder.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Easiest way would be to make a copy of the LegendSkin.mxml and replace the above method.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You can then apply this new skin class to the Legend component:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;
&amp;lt;esri:Legend id="myLegend"
&amp;nbsp;&amp;nbsp;&amp;nbsp; width="100%" height="100%"
&amp;nbsp;&amp;nbsp;&amp;nbsp; map="{myMap}"
&amp;nbsp;&amp;nbsp; respectCurrentMapScale="true"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; skinClass="MyLegendSkin"/&amp;gt;

&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope that clarifies things.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:07:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584329#M13123</guid>
      <dc:creator>SarthakDatt</dc:creator>
      <dc:date>2021-12-12T01:07:25Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584330#M13124</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Sarthak,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; I appreciate your help. Can you tell me where the LegendSkin.mxml&amp;nbsp; resides?&amp;nbsp; Unfortunately I am new to Flex and the skins concept&amp;nbsp; and have not been able to locate this mxml in the Package Explorer. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Greg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 15:54:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584330#M13124</guid>
      <dc:creator>GregMcNeill</dc:creator>
      <dc:date>2011-04-06T15:54:07Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584331#M13125</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Greg,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When you download the api, the skins folder is part of the zip. All the out of the box skins are in this folder:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;arcgis_api_for_flex_2_2 -&amp;gt;ArcGIS_Flex -&amp;gt; skins -&amp;gt; src -&amp;gt; com -&amp;gt; esri -&amp;gt; ags -&amp;gt; skins&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 17:23:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584331#M13125</guid>
      <dc:creator>SarthakDatt</dc:creator>
      <dc:date>2011-04-06T17:23:12Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584332#M13126</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Sarthak,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; I got it resolved thanks to your help and Sumedha at ESRI support.&amp;nbsp; I understand that 2.3 is in testing and close to release which will resolve this issue.&amp;nbsp; I am very grateful that you took the time to show me the mxl's behind the api. this was very cool.&amp;nbsp; I am attaching the code just in case anyone else can benefit.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Greg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Apr 2011 17:43:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584332#M13126</guid>
      <dc:creator>GregMcNeill</dc:creator>
      <dc:date>2011-04-06T17:43:03Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584333#M13127</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Sarthak and Greg,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I downloaded the code which you shared,but I am having issues with the treeview control in TOC and dynamic legends turn on/off..I am new to Flex,if you could help me on this please.. i think there is some issue in the skins componenet.. I have included it outside the src folder but still no success&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jun 2011 07:34:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584333#M13127</guid>
      <dc:creator>tanyabisen</dc:creator>
      <dc:date>2011-06-06T07:34:37Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584334#M13128</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Tanya,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; With the release of Flex API 2.3.1 you will not have to copy the LegendSkin.mxml from the API directory and modify the "visibleLayersChangeHandler()" that Sarthak had me do in my previous example.&amp;nbsp; Here is a updated version of that same application for use with the Flex API 2.3.1.&amp;nbsp; Hop[e this helps,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;-Greg&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Jun 2011 12:29:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584334#M13128</guid>
      <dc:creator>GregMcNeill</dc:creator>
      <dc:date>2011-06-06T12:29:39Z</dc:date>
    </item>
    <item>
      <title>Re: Coercion Error with ESRI Flex Legend Component</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584335#M13129</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Greg, It worked perfectly the way I wanted... If you could help me with creating a treeview in TOC which will include the annotations.. any link or reference you have would be great..\&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Tanya&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 22 Jun 2011 04:49:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/coercion-error-with-esri-flex-legend-component/m-p/584335#M13129</guid>
      <dc:creator>tanyabisen</dc:creator>
      <dc:date>2011-06-22T04:49:17Z</dc:date>
    </item>
  </channel>
</rss>

