<?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: add graphic with wrong extent in ArcGIS JavaScript Maps SDK Questions</title>
    <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348209#M32173</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;No I'm not using an outSpatialReference. Because I thought my graphic would automatically use my map.extent and my map SR.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I just added this to my findTask parameters and it worked well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;findParams.outSpatialReference = new esri.SpatialReference({ wkid: 102100 });&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 10 Dec 2012 13:10:44 GMT</pubDate>
    <dc:creator>YvanBérard</dc:creator>
    <dc:date>2012-12-10T13:10:44Z</dc:date>
    <item>
      <title>add graphic with wrong extent</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348205#M32169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi all, &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;recently I had a problem with the findTask, but I digged up more the problem and found that my graphic were added, but with the wrong extent.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Do you know how to solve the problem?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This is my original extent (situated in Quebec, Canada) :&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;var initialExtent = new esri.geometry.Extent({ 'xmin': -8034661, 'ymin': 5652797, 'xmax': -8004182, 'ymax': 5670187, 'spatialReference': new esri.SpatialReference({ wkid: 102100 }) });&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But, when the event add(graphic) is fired, the graphic are added in the middle of the mediterannean sea (?!?!?!???). How could this happen? I've never seen that bug.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;var graphic = new esri.Graphic(result.feature.geometry, sym); //create graphic with geometry (result.feature.geometry) and symbol (sym) &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; console.dir(map); &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; map._layers.search_result.add(graphic); //add graphic to graphics layer created above&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Dec 2012 11:46:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348205#M32169</guid>
      <dc:creator>YvanBérard</dc:creator>
      <dc:date>2012-12-10T11:46:31Z</dc:date>
    </item>
    <item>
      <title>Re: add graphic with wrong extent</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348206#M32170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Whats the spatial reference of result.feature?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Dec 2012 12:25:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348206#M32170</guid>
      <dc:creator>JeffPace</dc:creator>
      <dc:date>2012-12-10T12:25:43Z</dc:date>
    </item>
    <item>
      <title>Re: add graphic with wrong extent</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348207#M32171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;wkid: 32188&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;And I don't know why...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;it seems that this spatial reference is created automatically when there is a map._layers.search_result.add(graphic);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;How could I change the spatial reference of a graphic layer???&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Dec 2012 12:28:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348207#M32171</guid>
      <dc:creator>YvanBérard</dc:creator>
      <dc:date>2012-12-10T12:28:32Z</dc:date>
    </item>
    <item>
      <title>Re: add graphic with wrong extent</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348208#M32172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;thats very odd but i think we are on the correct path. Whatever is generating your result, are you specifying an outSR?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Dec 2012 13:02:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348208#M32172</guid>
      <dc:creator>JeffPace</dc:creator>
      <dc:date>2012-12-10T13:02:03Z</dc:date>
    </item>
    <item>
      <title>Re: add graphic with wrong extent</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348209#M32173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;No I'm not using an outSpatialReference. Because I thought my graphic would automatically use my map.extent and my map SR.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I just added this to my findTask parameters and it worked well.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;findParams.outSpatialReference = new esri.SpatialReference({ wkid: 102100 });&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Dec 2012 13:10:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348209#M32173</guid>
      <dc:creator>YvanBérard</dc:creator>
      <dc:date>2012-12-10T13:10:44Z</dc:date>
    </item>
    <item>
      <title>Re: add graphic with wrong extent</title>
      <link>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348210#M32174</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;No I'm not using an outSpatialReference. Because I thought my graphic would automatically use my map.extent and my map SR.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Only if the SR is undefined, in this case it looks like it is defined by the request/response and that is where the problem is.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Dec 2012 13:15:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-javascript-maps-sdk-questions/add-graphic-with-wrong-extent/m-p/348210#M32174</guid>
      <dc:creator>JeffPace</dc:creator>
      <dc:date>2012-12-10T13:15:08Z</dc:date>
    </item>
  </channel>
</rss>

