<?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: ApplyEdits geometry from javascript API in ArcGIS Server with JavaScript API Questions</title>
    <link>https://community.esri.com/t5/arcgis-server-with-javascript-api-questions/applyedits-geometry-from-javascript-api/m-p/814998#M377</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Has polygonSelfIntersecting been replaced by the polygon method &lt;SPAN class="pun"&gt;&lt;/SPAN&gt;&lt;SPAN class="pln"&gt;&lt;A href="https://developers.arcgis.com/javascript/jsapi/polygon-amd.html#isselfintersectinghttp://"&gt;isSelfIntersecting&lt;/A&gt;?&lt;/SPAN&gt;&lt;SPAN class="pun"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 05 Aug 2015 12:39:13 GMT</pubDate>
    <dc:creator>KenBuja</dc:creator>
    <dc:date>2015-08-05T12:39:13Z</dc:date>
    <item>
      <title>ApplyEdits geometry from javascript API</title>
      <link>https://community.esri.com/t5/arcgis-server-with-javascript-api-questions/applyedits-geometry-from-javascript-api/m-p/814996#M375</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I drew a graphic on a graphic layer (sample)&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Capture.PNG" class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/120571_Capture.PNG" style="height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;When running this through applyEdits on a featureLayer i get a success in return, but the geometry in the database becomes null or invalid.&lt;/P&gt;&lt;P&gt;If I draw a simple square or a circle, I don't see the same problem.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I also tried to take the same geometry into arcmap using json to features, the geometry appears correctly.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have attached a sample JSON which does not work through applyEdits (even though it returns success and attributes are saved)&lt;/P&gt;&lt;P&gt;However, the shape looks perfectly well when importing using json to features.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any hints on what could I could do wrong?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Aug 2015 15:42:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-server-with-javascript-api-questions/applyedits-geometry-from-javascript-api/m-p/814996#M375</guid>
      <dc:creator>Lars_HalvorAnundskaas</dc:creator>
      <dc:date>2015-08-04T15:42:14Z</dc:date>
    </item>
    <item>
      <title>Re: ApplyEdits geometry from javascript API</title>
      <link>https://community.esri.com/t5/arcgis-server-with-javascript-api-questions/applyedits-geometry-from-javascript-api/m-p/814997#M376</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;10.3.1 did not give me any error message, but 10.2.1 did:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The solution; to run simplify on the geometry when necessary&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;if (esri.geometry.polygonSelfIntersecting(geom)) {&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; geom = geometryEngine.simplify(geom);&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;EM&gt;}&lt;/EM&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://developers.arcgis.com/javascript/jssamples/util_simplify.html" title="https://developers.arcgis.com/javascript/jssamples/util_simplify.html"&gt;Simplify a polygon | ArcGIS API for JavaScript&lt;/A&gt; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Aug 2015 21:26:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-server-with-javascript-api-questions/applyedits-geometry-from-javascript-api/m-p/814997#M376</guid>
      <dc:creator>Lars_HalvorAnundskaas</dc:creator>
      <dc:date>2015-08-04T21:26:44Z</dc:date>
    </item>
    <item>
      <title>Re: ApplyEdits geometry from javascript API</title>
      <link>https://community.esri.com/t5/arcgis-server-with-javascript-api-questions/applyedits-geometry-from-javascript-api/m-p/814998#M377</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Has polygonSelfIntersecting been replaced by the polygon method &lt;SPAN class="pun"&gt;&lt;/SPAN&gt;&lt;SPAN class="pln"&gt;&lt;A href="https://developers.arcgis.com/javascript/jsapi/polygon-amd.html#isselfintersectinghttp://"&gt;isSelfIntersecting&lt;/A&gt;?&lt;/SPAN&gt;&lt;SPAN class="pun"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Aug 2015 12:39:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-server-with-javascript-api-questions/applyedits-geometry-from-javascript-api/m-p/814998#M377</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2015-08-05T12:39:13Z</dc:date>
    </item>
  </channel>
</rss>

