In ArcGIS Pro, it is possible to add a shapefile to a map. In some instances, attempting to do so fails and returns the following error message:
Failed to add data: <shapefile name>.shp
- The shapefile’s location folder contains missing files.
- The shapefile’s location folder contains misspelled file names.
- The shapefile is corrupt.
Solution or Workaround
Depending on the cause, use one of the workarounds below to resolve the issue.
After attempting a workaround, add the shapefile to the map in ArcGIS Pro. If the shapefile’s location folder is added as a folder connection, right-click the folder in the Catalog pane, and click Refresh before adding the shapefile to the map.
Ensure the shapefile’s folder contains all the necessary files
- Navigate to the shapefile’s folder, and identify the missing .shp, .shx, .dbf, and .prj files. In this example, the ‘California_Cities_csv.dbf’ file is missing.
- Search for and copy the backup copy of the file to the folder. Refer to How-To Geek: How to Copy or Move Files on Windows 10 for the steps to copy a file into a folder. The image below demonstrates a complete shapefile folder.
Rename all the misspelled files in the shapefile’s folder
- Navigate to the shapefile’s folder, and identify all the misspelled .shp, .shx, .dbf, and .prj file names. In this example, the ‘California_Cities_csv2.shx’ file is misspelled.
- Right-click the misspelled file’s name, and click Rename.
- Type a name, and press Enter. The image below demonstrates a complete shapefile folder with the correct file names.
Repair the corrupt shapefile
Recover the shapefile. Refer to How To: Recover a corrupt shapefile for more information.