<?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: arcpy.Delete_management not working on particular shpfiles. in Python Snippets Questions</title>
    <link>https://community.esri.com/t5/python-snippets-questions/arcpy-delete-management-not-working-on-particular/m-p/881856#M682</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;from here... &lt;A href="http://pro.arcgis.com/en/pro-app/tool-reference/data-management/delete.htm" style="background-color: transparent; color: #2989c5; font-family: Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size: 15px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px;" rel="nofollow noopener noreferrer" target="_blank"&gt;http://pro.arcgis.com/en/pro-app/tool-reference/data-management/delete.htm&lt;/A&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; arcpy
arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;env&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;workspace &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"C:/check"&lt;/SPAN&gt;
arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;Delete_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'Folklore.shp'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;of course the folder and the shape file must exist.&amp;nbsp; If there was a lock, then you would get an error.&lt;/P&gt;&lt;P&gt;You may need to refresh your views in Windows&amp;nbsp; to see changes and/or in whatever you are using to check to see if it is gone.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0b0119;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 12 Dec 2021 11:08:20 GMT</pubDate>
    <dc:creator>DanPatterson_Retired</dc:creator>
    <dc:date>2021-12-12T11:08:20Z</dc:date>
    <item>
      <title>arcpy.Delete_management not working on particular shpfiles.</title>
      <link>https://community.esri.com/t5/python-snippets-questions/arcpy-delete-management-not-working-on-particular/m-p/881855#M681</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi folks, I've been stuck on this for ages. Hopefully someone might have some tips. I have some code to delete a .shp file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;arcpy.env.workspace = "C:/check"&lt;BR /&gt;ws = arcpy.env.workspace&lt;BR /&gt;in_data = "Folklore.shp"&lt;BR /&gt;data_type = ""&lt;/P&gt;&lt;P&gt;arcpy.env.overwriteOutput = True &lt;BR /&gt;arcpy.Delete_management(in_data, data_type)&lt;BR /&gt;arcpy.Delete_management('Folklore.shp')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The shp file just won't delete. It seems to make it stop working but not delete. It is a points shp file. This code works fine if I delete a polygon shp file. So I don't think it is a problem with the code. Does anybody know of any particular issues with deleting certain types of shp files. There are no lock files. And ArcMAP and ArcCatalog are closed.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2018 19:57:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-snippets-questions/arcpy-delete-management-not-working-on-particular/m-p/881855#M681</guid>
      <dc:creator>ShaneStevenson</dc:creator>
      <dc:date>2018-04-24T19:57:55Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Delete_management not working on particular shpfiles.</title>
      <link>https://community.esri.com/t5/python-snippets-questions/arcpy-delete-management-not-working-on-particular/m-p/881856#M682</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;from here... &lt;A href="http://pro.arcgis.com/en/pro-app/tool-reference/data-management/delete.htm" style="background-color: transparent; color: #2989c5; font-family: Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size: 15px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px;" rel="nofollow noopener noreferrer" target="_blank"&gt;http://pro.arcgis.com/en/pro-app/tool-reference/data-management/delete.htm&lt;/A&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; arcpy
arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;env&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;workspace &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;"C:/check"&lt;/SPAN&gt;
arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;Delete_management&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'Folklore.shp'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;of course the folder and the shape file must exist.&amp;nbsp; If there was a lock, then you would get an error.&lt;/P&gt;&lt;P&gt;You may need to refresh your views in Windows&amp;nbsp; to see changes and/or in whatever you are using to check to see if it is gone.&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0b0119;"&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 11:08:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-snippets-questions/arcpy-delete-management-not-working-on-particular/m-p/881856#M682</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2021-12-12T11:08:20Z</dc:date>
    </item>
    <item>
      <title>Re: arcpy.Delete_management not working on particular shpfiles.</title>
      <link>https://community.esri.com/t5/python-snippets-questions/arcpy-delete-management-not-working-on-particular/m-p/881857#M683</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is it possible that the file's read-only attribute has been set?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 24 Apr 2018 20:59:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-snippets-questions/arcpy-delete-management-not-working-on-particular/m-p/881857#M683</guid>
      <dc:creator>RandyBurton</dc:creator>
      <dc:date>2018-04-24T20:59:06Z</dc:date>
    </item>
  </channel>
</rss>

