<?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: &amp;quot;where shapefile in use?&amp;quot; in ArcGIS Pro Questions</title>
    <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1378579#M78381</link>
    <description>&lt;P&gt;Hi &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/672591"&gt;@MarcBordelon&lt;/a&gt;!&lt;/P&gt;&lt;P&gt;I know this is the most obvious, safest and probably the only solution.&lt;/P&gt;&lt;P&gt;My question was to know if anyone knows of another procedure that might have the same result.&lt;/P&gt;&lt;P&gt;The best thing is to have everything well organized, which I didn't have.&lt;/P&gt;&lt;P&gt;Thanks for your tip.&lt;/P&gt;</description>
    <pubDate>Tue, 06 Feb 2024 10:23:55 GMT</pubDate>
    <dc:creator>AntónioRuiFernandes</dc:creator>
    <dc:date>2024-02-06T10:23:55Z</dc:date>
    <item>
      <title>"where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1375971#M78132</link>
      <description>&lt;P&gt;Hey guys.&lt;/P&gt;&lt;P&gt;I have a shapefile in a folder on my desktop and I'm afraid of deleting it.&lt;/P&gt;&lt;P&gt;Is there any way to know in which ArcGis project we are using a particular shapefile?&lt;/P&gt;&lt;P&gt;Thank you all.&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jan 2024 16:33:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1375971#M78132</guid>
      <dc:creator>AntónioRuiFernandes</dc:creator>
      <dc:date>2024-01-30T16:33:31Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1375981#M78133</link>
      <description>&lt;P&gt;There might be a way in ArcPy to loop through a series of projects and print off any data sources that are looking for a ".shp", but that's a bit outside of my expertise. I think you'll want the &lt;STRONG&gt;arcpy.mp &lt;/STRONG&gt;module:&lt;/P&gt;&lt;P&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/arcpy/mapping/layer-class.htm" target="_blank"&gt;https://pro.arcgis.com/en/pro-app/latest/arcpy/mapping/layer-class.htm&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jan 2024 16:47:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1375981#M78133</guid>
      <dc:creator>jcarlson</dc:creator>
      <dc:date>2024-01-30T16:47:27Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1375983#M78134</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/363906"&gt;@jcarlson&lt;/a&gt;. I'll follow your tip.&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jan 2024 16:52:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1375983#M78134</guid>
      <dc:creator>AntónioRuiFernandes</dc:creator>
      <dc:date>2024-01-30T16:52:13Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1376009#M78135</link>
      <description>&lt;P&gt;I'm all for a Python solution.&lt;/P&gt;&lt;P&gt;There are some sample snippets in this help topic:&lt;/P&gt;&lt;P&gt;&lt;A href="https://pro.arcgis.com/en/pro-app/latest/arcpy/mapping/updatingandfixingdatasources.htm" target="_blank"&gt;https://pro.arcgis.com/en/pro-app/latest/arcpy/mapping/updatingandfixingdatasources.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;There is an old sample for inventorying a folder of ArcMap (.mxd) maps and reporting their data sources, but it would need to adapted to work with ArcGIS Pro projects. You could borrow the document iteration and CSV report writing logic from there.&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.arcgis.com/home/item.html?id=18c19ec00acb4d568c27bc20a72bfdc8" target="_blank"&gt;https://www.arcgis.com/home/item.html?id=18c19ec00acb4d568c27bc20a72bfdc8&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Another approach would be to zip up that folder (or move it to an archive drive) and keep it around for a while. If you find you need it, put it where it makes sense and fix the layer.&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jan 2024 17:35:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1376009#M78135</guid>
      <dc:creator>BobBooth1</dc:creator>
      <dc:date>2024-01-30T17:35:53Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1376055#M78136</link>
      <description>&lt;P&gt;Something like this should work:&lt;/P&gt;&lt;LI-CODE lang="python"&gt;import arcpy
import os

def find_files(folder_path, file_extension):
    file_list = []
    for root, dirs, files in os.walk(folder_path):
        for file in files:
            if file.endswith(file_extension):
                file_list.append(os.path.join(root, file))
    return file_list

# Example usage
folder_path = 'C:\\Users\\my_user_name\\Documents\\ArcGIS\\Projects\\'
file_extension = '.aprx'
found_projects = find_files(folder_path, file_extension)
#print(found_projects)
for a_project in found_projects:
    aprx = arcpy.mp.ArcGISProject(a_project)
    the_maps = aprx.listMaps()
    for a_map in the_maps:
        layers = a_map.listLayers()
        for layer in layers:
            try:
                print(layer.dataSource)
                # Check if he shapefile is used in this layer
                if layer.dataSource == 'your_path_to_shapefile':
                    print("The data source is here!")
            except:
                print("problem, dataSource may not be supported")&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 30 Jan 2024 19:04:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1376055#M78136</guid>
      <dc:creator>BobBooth1</dc:creator>
      <dc:date>2024-01-30T19:04:38Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1376469#M78137</link>
      <description>&lt;P&gt;Thanks for your help,&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/95621"&gt;@BobBooth1&lt;/a&gt;&amp;nbsp;&lt;span class="lia-unicode-emoji" title=":thumbs_up:"&gt;👍&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 31 Jan 2024 15:11:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1376469#M78137</guid>
      <dc:creator>AntónioRuiFernandes</dc:creator>
      <dc:date>2024-01-31T15:11:32Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1377859#M78304</link>
      <description>A shape file (with all its files) will not tell you where its used. You will have to open your projects and see where that shp file has been used or remember what project you used it in. You can open your files that are in a folder and search it out. Those are the only ways to show where its been used.&amp;nbsp;&lt;BR /&gt;</description>
      <pubDate>Fri, 02 Feb 2024 22:57:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1377859#M78304</guid>
      <dc:creator>MarcBordelon</dc:creator>
      <dc:date>2024-02-02T22:57:42Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1378579#M78381</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/672591"&gt;@MarcBordelon&lt;/a&gt;!&lt;/P&gt;&lt;P&gt;I know this is the most obvious, safest and probably the only solution.&lt;/P&gt;&lt;P&gt;My question was to know if anyone knows of another procedure that might have the same result.&lt;/P&gt;&lt;P&gt;The best thing is to have everything well organized, which I didn't have.&lt;/P&gt;&lt;P&gt;Thanks for your tip.&lt;/P&gt;</description>
      <pubDate>Tue, 06 Feb 2024 10:23:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1378579#M78381</guid>
      <dc:creator>AntónioRuiFernandes</dc:creator>
      <dc:date>2024-02-06T10:23:55Z</dc:date>
    </item>
    <item>
      <title>Re: "where shapefile in use?"</title>
      <link>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1379494#M78448</link>
      <description>&lt;P&gt;You might consider creating an archive file geodatabase and convert it to a feature class.&amp;nbsp; Add some metadata about where it was originally stored so that you can restore it later if necessary.&amp;nbsp; If you already have multiple copies elsewhere just ignore what I wrote.&lt;/P&gt;</description>
      <pubDate>Thu, 08 Feb 2024 01:04:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-pro-questions/quot-where-shapefile-in-use-quot/m-p/1379494#M78448</guid>
      <dc:creator>RandyKreuziger1</dc:creator>
      <dc:date>2024-02-08T01:04:36Z</dc:date>
    </item>
  </channel>
</rss>

