<?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: export point as shapefile in Java Maps SDK Questions</title>
    <link>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1057527#M2364</link>
    <description>&lt;P&gt;and for browsing geopackage , what should i do. as i tried the given sample but not working.&lt;/P&gt;</description>
    <pubDate>Thu, 13 May 2021 10:40:38 GMT</pubDate>
    <dc:creator>NareshBansal</dc:creator>
    <dc:date>2021-05-13T10:40:38Z</dc:date>
    <item>
      <title>export point as shapefile</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055068#M2356</link>
      <description>&lt;P&gt;hii,&lt;/P&gt;&lt;P&gt;i'm working on arcgis runtime java maven application , I just want to know that how to export an sketch(point , line ,polygon) in shapefile format.&amp;nbsp;&lt;/P&gt;&lt;P&gt;please share sample code if available...&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/48868"&gt;@MarkBaird&lt;/a&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 06 May 2021 09:49:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055068#M2356</guid>
      <dc:creator>NareshBansal</dc:creator>
      <dc:date>2021-05-06T09:49:25Z</dc:date>
    </item>
    <item>
      <title>Re: export point as shapefile</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055120#M2359</link>
      <description>&lt;P&gt;I'm not completely sure of your workflow here, but how are you planning on drawing your sketches?&amp;nbsp; Are you planning on using graphics and maybe the sketch editor like in this &lt;A href="https://developers.arcgis.com/java/sample-code/sketch-on-map/" target="_self"&gt;sample&lt;/A&gt;?&lt;/P&gt;&lt;P&gt;If this is your plan, then you could write some code to move these geometries into an existing shapefile.&amp;nbsp; There is API which allows you to display and potentially edit shapefiles.&amp;nbsp; The &lt;A href="https://developers.arcgis.com/java/sample-code/feature-layer-shapefile/" target="_self"&gt;sample&lt;/A&gt; here shows how to open a shapefile.&amp;nbsp; &amp;nbsp;The&amp;nbsp;&lt;A title="ShapefileFeatureTable" href="https://developers.arcgis.com/java/api-reference/reference/com/esri/arcgisruntime/data/ShapefileFeatureTable.html" target="_blank" rel="noopener"&gt;ShapefileFeatureTable&lt;/A&gt;&amp;nbsp;class has methods for adding new features.&lt;/P&gt;&lt;P&gt;Remember that a shapefile can only contain one type of geometry.&amp;nbsp; For example if a shapefile schema is for points, then you can't write lines or polygons into the same file.&lt;/P&gt;&lt;P&gt;I would however consider if you really need to use the shapefile format here.&amp;nbsp; There are potentially better workflows for editing and sharing data, but I'd need to know a little more about the bigger picture of what you are trying to achieve.&lt;/P&gt;</description>
      <pubDate>Thu, 06 May 2021 09:58:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055120#M2359</guid>
      <dc:creator>MarkBaird</dc:creator>
      <dc:date>2021-05-06T09:58:17Z</dc:date>
    </item>
    <item>
      <title>Re: export point as shapefile</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055162#M2361</link>
      <description>&lt;P&gt;exactly,&amp;nbsp; you got the plan what i am asking for ,but want to know that how can i save these geometries into shapefile format as by clicking simple save button. and another , how can i browse any shapefile into my project by using add data button on UI ,i have created.&lt;/P&gt;</description>
      <pubDate>Thu, 06 May 2021 12:34:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055162#M2361</guid>
      <dc:creator>NareshBansal</dc:creator>
      <dc:date>2021-05-06T12:34:39Z</dc:date>
    </item>
    <item>
      <title>Re: export point as shapefile</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055180#M2362</link>
      <description>&lt;P&gt;From your picture it looks like you have a number of point based graphics which you have added.&amp;nbsp; Assuming you have a shapefile (potentially an empty one which is set up for point geometries) you can do something like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;- Loop through the graphics in your graphics overlay and for each graphic obtain the geometry (a point in your example).&lt;/P&gt;&lt;P&gt;&amp;nbsp;- For each geometry you will need to create a feature which matches the schema of your shape file.&amp;nbsp; A feature will contain the geometry and optionally attributes too.&lt;/P&gt;&lt;P&gt;&amp;nbsp;- Using the ShapefileFeatureTable class use the addFeature method&amp;nbsp;&lt;A href="https://developers.arcgis.com/java/api-reference/reference/com/esri/arcgisruntime/data/FeatureTable.html#addFeatureAsync(com.esri.arcgisruntime.data.Feature)" target="_blank"&gt;https://developers.arcgis.com/java/api-reference/reference/com/esri/arcgisruntime/data/FeatureTable.html#addFeatureAsync(com.esri.arcgisruntime.data.Feature).&amp;nbsp; &lt;/A&gt;&lt;/P&gt;&lt;P&gt;(Note that ShapefileFeatureTable inherits from FeatureTable)&lt;/P&gt;&lt;P&gt;There isn't a specific sample showing how to add features to a shapefile, but essentially its the same for any data source so these references will help:&lt;/P&gt;&lt;P&gt;&amp;nbsp;-&amp;nbsp;&lt;A href="https://developers.arcgis.com/java/query-and-edit/edit/" target="_blank"&gt;https://developers.arcgis.com/java/query-and-edit/edit/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;-&amp;nbsp;&lt;A href="https://developers.arcgis.com/java/sample-code/add-features/" target="_blank"&gt;https://developers.arcgis.com/java/sample-code/add-features/&lt;/A&gt;&lt;/P&gt;&lt;P&gt;As for browsing shapefiles, just use the JavaFX file chooser and look for .shp files.&amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 06 May 2021 13:13:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1055180#M2362</guid>
      <dc:creator>MarkBaird</dc:creator>
      <dc:date>2021-05-06T13:13:08Z</dc:date>
    </item>
    <item>
      <title>Re: export point as shapefile</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1057527#M2364</link>
      <description>&lt;P&gt;and for browsing geopackage , what should i do. as i tried the given sample but not working.&lt;/P&gt;</description>
      <pubDate>Thu, 13 May 2021 10:40:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1057527#M2364</guid>
      <dc:creator>NareshBansal</dc:creator>
      <dc:date>2021-05-13T10:40:38Z</dc:date>
    </item>
    <item>
      <title>Re: export point as shapefile</title>
      <link>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1057532#M2365</link>
      <description>&lt;P&gt;GeoPackages are separate to shapefiles so if you have specific questions about GeoPackages then its best if you start a fresh question.&amp;nbsp; This makes the forum easier to search for answers.&lt;/P&gt;&lt;P&gt;This sample shows how to display the contents of a GeoPackage&amp;nbsp;&lt;A href="https://github.com/Esri/arcgis-runtime-samples-java/tree/master/feature_layers/feature-layer-geopackage" target="_blank"&gt;https://github.com/Esri/arcgis-runtime-samples-java/tree/master/feature_layers/feature-layer-geopackage&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 13 May 2021 11:29:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/java-maps-sdk-questions/export-point-as-shapefile/m-p/1057532#M2365</guid>
      <dc:creator>MarkBaird</dc:creator>
      <dc:date>2021-05-13T11:29:36Z</dc:date>
    </item>
  </channel>
</rss>

