<?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: Bug in legend widget? Grouped legend values appear multiple times in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729332#M67629</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Steve and Jeff,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I updated a service to try and reproduce the problem but my legend doesn't display multiple items. The test service is public:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://servicesbeta.esri.com/ArcGIS/rest/services/SanJuan/Trails/MapServer"&gt;https://servicesbeta.esri.com/ArcGIS/rest/services/SanJuan/Trails/MapServer&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The Trail Conditions layer has a unique value renderer and I grouped two of the items (maintenance and bridge). I also created a group layer (Trails, Regional Trail Conditions) just in case that was the issue. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I then modified the Legend Widget sample from the help to use the San Juan layer and in my tests there are no duplicate items. Is there something in your service that is substantially different?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 29 Dec 2010 21:20:59 GMT</pubDate>
    <dc:creator>KellyHutchins</dc:creator>
    <dc:date>2010-12-29T21:20:59Z</dc:date>
    <item>
      <title>Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729327#M67624</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;In ArcMap, create a Unique Values symbology, select multiple categories, then right-click and Group them.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Publish to ArcGIS Server and add as a dynamic map service. Using the new JS API version 2.1 legend widget, create a legend from this layer.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm finding that the grouped categories display multiple times. Eg, if the group consists of 3 individual categories, the (identical) symbol will appear in the legend 3 times.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Please let me know if you need any further information to reproduce this bug.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;PS I have no idea why this title has a smiley face. Maybe that's another bug.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 09 Dec 2010 21:45:15 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729327#M67624</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2010-12-09T21:45:15Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729328#M67625</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Any response from ESRI?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;What's the best way to submit this as a bug report, given that I'm an EDN customer so don't have access to the full tech support?&lt;/SPAN&gt;&lt;BR /&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>Wed, 15 Dec 2010 21:10:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729328#M67625</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2010-12-15T21:10:25Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729329#M67626</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Do you have a test service that shows the problem?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Any response from ESRI?&lt;BR /&gt;&lt;BR /&gt;What's the best way to submit this as a bug report, given that I'm an EDN customer so don't have access to the full tech support?&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Steve&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Dec 2010 18:54:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729329#M67626</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2010-12-16T18:54:41Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729330#M67627</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Kelly,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Unfortunately my server isn't yet accessible externally. But hopefully the description above is enough for you to recreate a similar service? Basically just use a Unique Values renderer, select a couple of classes, and choose Group.&lt;/SPAN&gt;&lt;BR /&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, 17 Dec 2010 02:43:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729330#M67627</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2010-12-17T02:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729331#M67628</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Do you have a test service that shows the problem?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Kelly, We are experiencing this same issue and we don't have a outward facing server yet to show you.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;We used the same steps as Steve, symbolize a layer and group in Symbology tab in Layer Properties.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just thought you should know.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Dec 2010 21:01:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729331#M67628</guid>
      <dc:creator>JeffLegato</dc:creator>
      <dc:date>2010-12-29T21:01:38Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729332#M67629</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Steve and Jeff,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I updated a service to try and reproduce the problem but my legend doesn't display multiple items. The test service is public:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="https://servicesbeta.esri.com/ArcGIS/rest/services/SanJuan/Trails/MapServer"&gt;https://servicesbeta.esri.com/ArcGIS/rest/services/SanJuan/Trails/MapServer&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The Trail Conditions layer has a unique value renderer and I grouped two of the items (maintenance and bridge). I also created a group layer (Trails, Regional Trail Conditions) just in case that was the issue. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I then modified the Legend Widget sample from the help to use the San Juan layer and in my tests there are no duplicate items. Is there something in your service that is substantially different?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 29 Dec 2010 21:20:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729332#M67629</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2010-12-29T21:20:59Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729333#M67630</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Kelly,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Your legend works fine for me, so I'm not sure what the problem is. Once our web server is outwardly facing I'll get you to try it and see if we can reproduce the problem.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Jan 2011 21:13:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729333#M67630</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2011-01-03T21:13:09Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729334#M67631</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Sounds good Steve, I'll try a few different tests as well to see if I can reproduce here as well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hi Kelly,&lt;BR /&gt;&lt;BR /&gt;Your legend works fine for me, so I'm not sure what the problem is. Once our web server is outwardly facing I'll get you to try it and see if we can reproduce the problem.&lt;BR /&gt;&lt;BR /&gt;Cheers,&lt;BR /&gt;Steve&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Jan 2011 15:38:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729334#M67631</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2011-01-04T15:38:32Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729335#M67632</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Kelly,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Just a thought - I'm using an MSD file as input for the service. I've noticed that there's sometimes a difference when an MSD vs MXD file is used, which might be the case here?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 Jan 2011 23:09:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729335#M67632</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2011-01-06T23:09:00Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729336#M67633</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm getting this same problem Steve - did you manage to find a solution? I'm using MXD's so I don't think it's anything to do with that.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Jan 2011 12:16:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729336#M67633</guid>
      <dc:creator>MR</dc:creator>
      <dc:date>2011-01-11T12:16:37Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729337#M67634</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I tested with both msd and mxd and can't reproduce but I'll keep researching this.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Jan 2011 15:02:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729337#M67634</guid>
      <dc:creator>KellyHutchins</dc:creator>
      <dc:date>2011-01-11T15:02:48Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729338#M67635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Kelly.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As a workaround, I created a new field and calculated the value that I wanted to appear in the legend, and used this to set the symbology.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 11 Jan 2011 22:18:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729338#M67635</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2011-01-11T22:18:30Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729339#M67636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Kelly,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Try making a legend from the feature service at:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://203.14.35.213/ArcGis1/rest/services/atlas/NaturalEnvironment_NationalParks/MapServer/0"&gt;http://203.14.35.213/ArcGis1/rest/services/atlas/NaturalEnvironment_NationalParks/MapServer/0&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm finding that the Other category appears 4 times, as there are 4 classes which I've combined into a single class.&lt;/SPAN&gt;&lt;BR /&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>Tue, 15 Mar 2011 23:58:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729339#M67636</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2011-03-15T23:58:45Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729340#M67637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Guys,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am coming across the same problem. In fact, it is not a bug with the legend widget, it has to do with how the rest service is defined from your layer symbology setup in ArcMap. I am building my own custom TOC and this had me stumped for a while. It happens in two instances that I am aware of:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;- using "Unique values" in ArcMap, selecting a few categories and grouping them manually&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- using "Unique values, many fields" in ArcMap (example in the attached esri_001.jpg)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When you check the rest service information, you will see some 17 entries under "Unique Value Infos: ". Which is essentially re-splitting your groups and undoing all your hard work! (abbreviated screenshot at esri_002.jpg)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So, you &lt;/SPAN&gt;&lt;SPAN style="font-style:italic;"&gt;can &lt;/SPAN&gt;&lt;SPAN&gt;workaround by creating a new column, and manually creating unique categories, but since our data is held in someone else's database, this is not an option for us.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there some other approach to this? And/or will ESRI be looking at why this happens in Rest and if it can be fixed?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Richard.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 18 Mar 2011 09:39:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729340#M67637</guid>
      <dc:creator>RichardKaufholz</dc:creator>
      <dc:date>2011-03-18T09:39:37Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729341#M67638</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Any update on this? we have the same problem.&amp;nbsp; If there are 4 values (even groups) in the mxd, there should only be 4 values in the legend.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hi Guys,&lt;BR /&gt;&lt;BR /&gt;I am coming across the same problem. In fact, it is not a bug with the legend widget, it has to do with how the rest service is defined from your layer symbology setup in ArcMap. I am building my own custom TOC and this had me stumped for a while. It happens in two instances that I am aware of:&lt;BR /&gt;&lt;BR /&gt;- using "Unique values" in ArcMap, selecting a few categories and grouping them manually&lt;BR /&gt;- using "Unique values, many fields" in ArcMap (example in the attached esri_001.jpg)&lt;BR /&gt;&lt;BR /&gt;When you check the rest service information, you will see some 17 entries under "Unique Value Infos: ". Which is essentially re-splitting your groups and undoing all your hard work! (abbreviated screenshot at esri_002.jpg)&lt;BR /&gt;&lt;BR /&gt;So, you &lt;SPAN style="font-style:italic;"&gt;can &lt;/SPAN&gt;workaround by creating a new column, and manually creating unique categories, but since our data is held in someone else's database, this is not an option for us.&lt;BR /&gt;&lt;BR /&gt;Is there some other approach to this? And/or will ESRI be looking at why this happens in Rest and if it can be fixed?&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Richard.&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Nov 2011 13:58:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729341#M67638</guid>
      <dc:creator>JeffPace</dc:creator>
      <dc:date>2011-11-23T13:58:28Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729342#M67639</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;it is not a bug with the legend widget, it has to do with how the rest service is defined from your layer symbology setup in ArcMap&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Richard, I think you're right. Perhaps we should be reporting this to the core ArcGIS Server or REST team, since it's nothing to do with the JS API.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm not on maintenance so I can't log a bug report - can someone else do it?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Steve&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Nov 2011 20:33:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729342#M67639</guid>
      <dc:creator>StephenLead</dc:creator>
      <dc:date>2011-11-23T20:33:25Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729343#M67640</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Richard, I think you're right. Perhaps we should be reporting this to the core ArcGIS Server or REST team, since it's nothing to do with the JS API.&lt;BR /&gt;&lt;BR /&gt;I'm not on maintenance so I can't log a bug report - can someone else do it?&lt;BR /&gt;&lt;BR /&gt;Cheers,&lt;BR /&gt;Steve&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Done &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; In May &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;#NIM067830&amp;nbsp; When using symbology of unique values, getting a duplicate entry in the legend service of the REST endpoint&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 Nov 2011 16:32:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729343#M67640</guid>
      <dc:creator>JeffPace</dc:creator>
      <dc:date>2011-11-28T16:32:10Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729344#M67641</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Done &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; In May &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;#NIM067830&amp;nbsp; When using symbology of unique values, getting a duplicate entry in the legend service of the REST endpoint&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Just checked.&amp;nbsp; This bug was submitted may 5th, 2011.&amp;nbsp; Medium Severity.&amp;nbsp; Not fixed.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Nov 2011 15:28:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729344#M67641</guid>
      <dc:creator>JeffPace</dc:creator>
      <dc:date>2011-11-30T15:28:02Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729345#M67642</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have recently began using the TOC widget for a Java App, Does anyone know how to make it so all layers are off and all groups are collapsed by default? Thank you.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Jan 2014 21:42:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729345#M67642</guid>
      <dc:creator>BrianMcLeer1</dc:creator>
      <dc:date>2014-01-24T21:42:39Z</dc:date>
    </item>
    <item>
      <title>Re: Bug in legend widget? Grouped legend values appear multiple times</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729346#M67643</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;If you're talking about NLiu's &lt;/SPAN&gt;&lt;A href="http://www.arcgis.com/home/item.html?id=9b6280a6bfb0430f8d1ebc969276b109"&gt;TOC widget&lt;/A&gt;&lt;SPAN&gt;, you'll find the documentation &lt;/SPAN&gt;&lt;A href="http://gmaps-utility-gis.googlecode.com/svn/tags/agsjs/latest/docs/toc/reference.html"&gt;here&lt;/A&gt;&lt;SPAN&gt;. By setting the visible layers for all the layers to -1, all groups will be collapsed.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 27 Jan 2014 13:55:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/bug-in-legend-widget-grouped-legend-values-appear/m-p/729346#M67643</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2014-01-27T13:55:58Z</dc:date>
    </item>
  </channel>
</rss>

