<?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: change fill color of esri.toolbars.Draw.EXTENT in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490462#M45570</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;To anybody that is interested, I figured out how to change the fill color.&amp;nbsp; Here's my code.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;// query for the rect element - not map_graphics_layer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;var extentBoxElement = dojo.query('rect')[0];&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;// set fill to red&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;extentBox.setAttribute('fill',"rgb(255, 0, 0)");&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This only works in FF though.&amp;nbsp; IE generates 'Error: Member not found' during setAttribute.&amp;nbsp; Inspection of the element in Firebug Lite shows there is no fill attribute and it's not obvious what attribute is being used for fill.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If anybody knows how to change the fill in IE 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;BLOCKQUOTE class="jive-quote"&gt;Hello,&lt;BR /&gt;I want to change the fill color of the esri.toolbars.Draw.EXTENT box on the fly while it is being drawn on the map to show the user has reached some limit.&amp;nbsp; How do I do that?&amp;nbsp; Through Firebug I've found the node that contains the fill information and it looks like this:&lt;BR /&gt;&amp;lt;g id="map_graphics_layer" style="display: block;" transform="matrix(1, 0, 0, 1, 0, 0)"&amp;gt;&amp;lt;rect fill="rgb(0, 0, 0)" fill-opacity="0.25" stroke="rgb(255, 0, 0)" stroke-opacity="1" stroke-width="2" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" x="522" y="177" width="26" height="19" stroke-dasharray="none" dojoGfxStrokeStyle="solid" fill-rule="evenodd"/&amp;gt;&amp;lt;/g&amp;gt;&lt;BR /&gt;&lt;BR /&gt;Programmatically, I'm able to&amp;nbsp; get that node using var extentBox = dojo.byId("map_graphics_layer").&amp;nbsp; And I can see the rect element but how do I edit the fill attribute?&lt;BR /&gt;&lt;BR /&gt;Any help would be appreciated.&lt;BR /&gt;Todd&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 May 2010 09:10:51 GMT</pubDate>
    <dc:creator>todddoerr</dc:creator>
    <dc:date>2010-05-05T09:10:51Z</dc:date>
    <item>
      <title>change fill color of esri.toolbars.Draw.EXTENT</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490461#M45569</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I want to change the fill color of the esri.toolbars.Draw.EXTENT box on the fly while it is being drawn on the map to show the user has reached some limit.&amp;nbsp; How do I do that?&amp;nbsp; Through Firebug I've found the node that contains the fill information and it looks like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;lt;g id="map_graphics_layer" style="display: block;" transform="matrix(1, 0, 0, 1, 0, 0)"&amp;gt;&amp;lt;rect fill="rgb(0, 0, 0)" fill-opacity="0.25" stroke="rgb(255, 0, 0)" stroke-opacity="1" stroke-width="2" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" x="522" y="177" width="26" height="19" stroke-dasharray="none" dojoGfxStrokeStyle="solid" fill-rule="evenodd"/&amp;gt;&amp;lt;/g&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Programmatically, I'm able to&amp;nbsp; get that node using var extentBox = dojo.byId("map_graphics_layer").&amp;nbsp; And I can see the rect element but how do I edit the fill attribute?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any help would be appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Todd&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 27 Apr 2010 13:12:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490461#M45569</guid>
      <dc:creator>todddoerr</dc:creator>
      <dc:date>2010-04-27T13:12:18Z</dc:date>
    </item>
    <item>
      <title>Re: change fill color of esri.toolbars.Draw.EXTENT</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490462#M45570</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;To anybody that is interested, I figured out how to change the fill color.&amp;nbsp; Here's my code.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;// query for the rect element - not map_graphics_layer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;var extentBoxElement = dojo.query('rect')[0];&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;// set fill to red&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;extentBox.setAttribute('fill',"rgb(255, 0, 0)");&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This only works in FF though.&amp;nbsp; IE generates 'Error: Member not found' during setAttribute.&amp;nbsp; Inspection of the element in Firebug Lite shows there is no fill attribute and it's not obvious what attribute is being used for fill.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If anybody knows how to change the fill in IE 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;BLOCKQUOTE class="jive-quote"&gt;Hello,&lt;BR /&gt;I want to change the fill color of the esri.toolbars.Draw.EXTENT box on the fly while it is being drawn on the map to show the user has reached some limit.&amp;nbsp; How do I do that?&amp;nbsp; Through Firebug I've found the node that contains the fill information and it looks like this:&lt;BR /&gt;&amp;lt;g id="map_graphics_layer" style="display: block;" transform="matrix(1, 0, 0, 1, 0, 0)"&amp;gt;&amp;lt;rect fill="rgb(0, 0, 0)" fill-opacity="0.25" stroke="rgb(255, 0, 0)" stroke-opacity="1" stroke-width="2" stroke-linecap="butt" stroke-linejoin="miter" stroke-miterlimit="4" x="522" y="177" width="26" height="19" stroke-dasharray="none" dojoGfxStrokeStyle="solid" fill-rule="evenodd"/&amp;gt;&amp;lt;/g&amp;gt;&lt;BR /&gt;&lt;BR /&gt;Programmatically, I'm able to&amp;nbsp; get that node using var extentBox = dojo.byId("map_graphics_layer").&amp;nbsp; And I can see the rect element but how do I edit the fill attribute?&lt;BR /&gt;&lt;BR /&gt;Any help would be appreciated.&lt;BR /&gt;Todd&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 May 2010 09:10:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490462#M45570</guid>
      <dc:creator>todddoerr</dc:creator>
      <dc:date>2010-05-05T09:10:51Z</dc:date>
    </item>
    <item>
      <title>Re: change fill color of esri.toolbars.Draw.EXTENT</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490463#M45571</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I'm kinda late but how about esri.toolbars.Draw.setFillSymbol() when you cross some threshold?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi/draw.htm#setFillSymbol"&gt;http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi/draw.htm#setFillSymbol&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 06 May 2010 22:09:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490463#M45571</guid>
      <dc:creator>DerekSwingley</dc:creator>
      <dc:date>2010-05-06T22:09:16Z</dc:date>
    </item>
    <item>
      <title>Re: change fill color of esri.toolbars.Draw.EXTENT</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490464#M45572</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thank you.&amp;nbsp; That is a much better solution.&amp;nbsp; I just needed to read and understand the JS API better.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks again.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;I'm kinda late but how about esri.toolbars.Draw.setFillSymbol() when you cross some threshold?&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi/draw.htm#setFillSymbol"&gt;http://help.arcgis.com/en/webapi/javascript/arcgis/help/jsapi/draw.htm#setFillSymbol&lt;/A&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 09 May 2010 13:52:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/change-fill-color-of-esri-toolbars-draw-extent/m-p/490464#M45572</guid>
      <dc:creator>todddoerr</dc:creator>
      <dc:date>2010-05-09T13:52:55Z</dc:date>
    </item>
  </channel>
</rss>

