<?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: Table of Contents (TOC) and Legend in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/table-of-contents-toc-and-legend/m-p/146331#M3401</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Can anybody offer any help for this? I know it would probably be easy for the Flex wizards we have here &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 09 Mar 2012 12:21:00 GMT</pubDate>
    <dc:creator>ionarawilson1</dc:creator>
    <dc:date>2012-03-09T12:21:00Z</dc:date>
    <item>
      <title>Table of Contents (TOC) and Legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/table-of-contents-toc-and-legend/m-p/146329#M3399</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Default Table of Contents (TOC) and Legend&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Hi folks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; I need help with the TOC Table of Content ArcScript posted on the arcscript page by Tom Hill. I am developing a Flex app outside of the Flex Viewer. I need to have the Group TOC and the legends. I was already able to put together the website with the map, the group TOC and the legend using the esri Legend component. What I need help is with the following:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1 - Have one layer always visible (in my case the county layer)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2 - Have all the other layers off when another layer (other than the layer that is always visible, the counties layer) is checked on&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3- Have the legend pop up for the layer that is checked on (right now I would have the legend visible for all the layers that are checked on, I just need to have one single for the one layer checked on)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 4- When there are two sublayers, the legends should be side-by-side not on top of one another vertically&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; I am attaching the image of my web app, the TOC arcscript I usde for the group TOC and part of the script of my main app so far:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;!-- Forestry --&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;esri:ArcGISDynamicMapServiceLayer id="ForIndirectBusinessTax" visible="false" url="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_indirect_bus_tax_nocache/MapServer" rel="nofollow" target="_blank"&gt;http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_indirect_bus_tax_nocache/MapServer&lt;/A&gt;&lt;SPAN&gt;" /&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;esri:ArcGISDynamicMapServiceLayer id="ForLaborOutput" visible="false" url="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_labor_ouptput_nocache/MapServer" rel="nofollow" target="_blank"&gt;http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_labor_ouptput_nocache/MapServer&lt;/A&gt;&lt;SPAN&gt;" /&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;esri:ArcGISDynamicMapServiceLayer id="ForEmploymentOutput" visible="false" url="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_employment_ouptput_nocache/MapServer" rel="nofollow" target="_blank"&gt;http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_employment_ouptput_nocache/MapServer&lt;/A&gt;&lt;SPAN&gt;" /&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;esri:ArcGISDynamicMapServiceLayer id="ForIndustryOutput" visible="false" url="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_industry_ouptput_notcache/MapServer" rel="nofollow" target="_blank"&gt;http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_added_forestry_industry_ouptput_notcache/MapServer&lt;/A&gt;&lt;SPAN&gt;"/&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;!-- Counties--&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;esri:ArcGISDynamicMapServiceLayer id="Labels" visible="true" url="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_LABELS2/MapServer" rel="nofollow" target="_blank"&gt;http://tfs-24279/ArcGIS/rest/services/TFEI_sorted_counties_2009_totals_LABELS2/MapServer&lt;/A&gt;&lt;SPAN&gt;" /&amp;gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/esri:Map&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:Panel&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:VBox&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:VBox height="1270" &amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:VBox height="490" width="570" &amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Panel title="Map Content" &amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;maplib:TOCAccordion height="450" width="100%" map="{map}" useLayerFadeEffect="true" labelFunction="{layerLabelFunc}"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;maplib:categories&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;!-- Each TOC category contains a label and an array of layer IDs. --&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Counties" layers="[Labels]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Forestry" layers="[ForIndustryOutput, ForEmploymentOutput, ForLaborOutput, ForIndirectBusinessTax]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Logging" layers="[LogIndustryOutput, LogEmploymentOutput, LogLaborOutput, LogIndirectBusinessTax]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Primary Paper and Paperboard" layers="[PrimaryPaperIndustryOutput, PrimaryPaperEmploymentOutput, PrimaryPaperLaborOutput, PrimaryPaperIndirectBusinessTax]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Primary Solid Wood Products" layers="[PrimarySolidIndustryOutput, PrimarySolidEmploymentOutput, PrimarySolidLaborOutput, PrimarySolidIndirectBusinessTax]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Secondary Paper and Paperboard" layers="[SecondaryPaperIndustryOutput, SecondaryPaperEmploymentOutput, SecondaryPaperLaborOutput, SecondaryPaperIndirectBusinessTax]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Secondary Solid Wood Products" layers="[SSecondarySolidIndustryOutput, SSecondarySolidEmploymentOutput, SSecondarySolidLaborOutput, SSecondarySolidIndirectBusinessTax]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:Object label="Total" layers="[TotalIndustryOutput, TotalEmploymentOutput, TotalLaborOutput, TotalIndirectBusinessTax]"/&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/maplib:categories&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/maplib:TOCAccordion&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:Panel&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:VBox&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;!-- &amp;lt;mx:VBox height="5" borderStyle="solid"&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:VBox&amp;gt;--&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;mx:HBox width="570" height="408" &amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;esri:Legend id="myLegend"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; layers="{[ TotalLaborOutput ]}"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; map="{map}"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; scaleY="0.9"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; width="100%"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; height="100%"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; respectCurrentMapScale="true"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; right="5" bottom="10"&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; /&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:HBox &amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:VBox&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/mx:HBox&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Any help is greatly appreciated! I am new to Flex and ActionScript so I am not sure yet how to implement this! I love Flex ! Thanks!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2012 15:16:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/table-of-contents-toc-and-legend/m-p/146329#M3399</guid>
      <dc:creator>ionarawilson1</dc:creator>
      <dc:date>2012-03-08T15:16:06Z</dc:date>
    </item>
    <item>
      <title>Re: Table of Contents (TOC) and Legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/table-of-contents-toc-and-legend/m-p/146330#M3400</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Original User: ionara_wilson&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Actually for the legend I would just have one legend (for the map that is showing, the only one checked and visible on the TOC&amp;nbsp; (besides the counties layer that does not need a legend)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any ideas?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Mar 2012 19:14:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/table-of-contents-toc-and-legend/m-p/146330#M3400</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2012-03-08T19:14:01Z</dc:date>
    </item>
    <item>
      <title>Re: Table of Contents (TOC) and Legend</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/table-of-contents-toc-and-legend/m-p/146331#M3401</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Can anybody offer any help for this? I know it would probably be easy for the Flex wizards we have here &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 09 Mar 2012 12:21:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/table-of-contents-toc-and-legend/m-p/146331#M3401</guid>
      <dc:creator>ionarawilson1</dc:creator>
      <dc:date>2012-03-09T12:21:00Z</dc:date>
    </item>
  </channel>
</rss>

