<?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 Possible to combine Class Breaks Renderer with Generate Renderer? in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/possible-to-combine-class-breaks-renderer-with/m-p/381880#M35453</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to produce an application similar to the Generate Renderer sample on the ArcGIS API for JavaScript website:&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/jssamples/renderer_generate_renderer.html" title="https://developers.arcgis.com/javascript/jssamples/renderer_generate_renderer.html"&gt;Generate renderer | ArcGIS API for JavaScript&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is that I want to use it with fields that contain some text values as well, which seems to break this code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, the Class Breaks Renderer API seems to work just fine with the fields I want to use, which allows me to symbolize based on class breaks and symbology that I define for certain value ranges AND set symbology for the values that are text.&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/jssamples/renderer_class_breaks.html" title="https://developers.arcgis.com/javascript/jssamples/renderer_class_breaks.html"&gt;Class breaks renderer | ArcGIS API for JavaScript&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The only problem is that the Class Breaks Renderer code does not contain a drop down menu to select a different field and re-generate the symbology for the values in the selected field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to combine these two samples so that I can select a new field from my feature service and regenerate symbology based on those values?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think that what I need to do is replace the variables for "ClassBreaksDefinition" and "AlgorithmicColorRamp," within the Generate Renderer code, with the "ClassBreaksRenderer" variable from the Class Breaks Renderer code.&amp;nbsp; At the same time, I guess I also need to find a way to specify symbology (SimpleFillSymbol) for the few text values in my data that aren't defined by the class breaks and display all of this in a legend...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be welcomed!&amp;nbsp; Thanks for reading. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've attached the code that I am working with.&amp;nbsp; Sorry the service URL is not shared to the public, I will try to fix that.&lt;/P&gt;&lt;P&gt;Notice that I point to fields that contain some string values with the "ClassBreaks" Sample.&amp;nbsp; The fields used for the "GenerateRenderer" sample are integer type and contain no string values, since the string type fields seemed to not work properly with that sample.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 15 Jan 2015 18:51:59 GMT</pubDate>
    <dc:creator>BrantCarman</dc:creator>
    <dc:date>2015-01-15T18:51:59Z</dc:date>
    <item>
      <title>Possible to combine Class Breaks Renderer with Generate Renderer?</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/possible-to-combine-class-breaks-renderer-with/m-p/381880#M35453</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying to produce an application similar to the Generate Renderer sample on the ArcGIS API for JavaScript website:&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/jssamples/renderer_generate_renderer.html" title="https://developers.arcgis.com/javascript/jssamples/renderer_generate_renderer.html"&gt;Generate renderer | ArcGIS API for JavaScript&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is that I want to use it with fields that contain some text values as well, which seems to break this code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, the Class Breaks Renderer API seems to work just fine with the fields I want to use, which allows me to symbolize based on class breaks and symbology that I define for certain value ranges AND set symbology for the values that are text.&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/jssamples/renderer_class_breaks.html" title="https://developers.arcgis.com/javascript/jssamples/renderer_class_breaks.html"&gt;Class breaks renderer | ArcGIS API for JavaScript&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The only problem is that the Class Breaks Renderer code does not contain a drop down menu to select a different field and re-generate the symbology for the values in the selected field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to combine these two samples so that I can select a new field from my feature service and regenerate symbology based on those values?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think that what I need to do is replace the variables for "ClassBreaksDefinition" and "AlgorithmicColorRamp," within the Generate Renderer code, with the "ClassBreaksRenderer" variable from the Class Breaks Renderer code.&amp;nbsp; At the same time, I guess I also need to find a way to specify symbology (SimpleFillSymbol) for the few text values in my data that aren't defined by the class breaks and display all of this in a legend...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help would be welcomed!&amp;nbsp; Thanks for reading. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've attached the code that I am working with.&amp;nbsp; Sorry the service URL is not shared to the public, I will try to fix that.&lt;/P&gt;&lt;P&gt;Notice that I point to fields that contain some string values with the "ClassBreaks" Sample.&amp;nbsp; The fields used for the "GenerateRenderer" sample are integer type and contain no string values, since the string type fields seemed to not work properly with that sample.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Jan 2015 18:51:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/possible-to-combine-class-breaks-renderer-with/m-p/381880#M35453</guid>
      <dc:creator>BrantCarman</dc:creator>
      <dc:date>2015-01-15T18:51:59Z</dc:date>
    </item>
  </channel>
</rss>

