PROBLEM

The Batch KML To Layer tool fails when converting multiple KML files

Last Published: October 12, 2021

Description

In ArcGIS Pro, attempts to convert multiple KML files to shapefiles using the Batch KML To Layer tool fail, and return the following error message:

Error:   
Error 000258: Output <value> already exists.
The Error:000258 message

Cause

The Output Data Name did not include '%Name%' at the end of the file name.

The Batch KML To Layer tool creates multiple geodatabases based on the name of the converted KML layer file, and these KML layer files are denoted by the '%Name%' expression. The correct format for naming the file is as follows:

<desired file name>_%Name%

Omitting this expression prevents the tool from creating multiple geodatabases, as once the first geodatabase is created for the first layer, subsequent geodatabases cannot be created as the tool attempts to create these geodatabases using the same name.

Solution or Workaround

  1. In ArcGIS Pro, navigate to Analysis > Tools.
  2. In the Geoprocessing pane, search for KML To Layer tool in the search box.
Search for KML To Layer tool in the geoprocessing pane.
  1. Right-click the KML To Layer tool, and click Batch.
Select Batch tool
  1. In the Batch KML To Layer pane, under Choose a batch parameter, select the Make temporary batch tool option.
  2. Use the default details for Name and Location. Click Next.
Select a batch parameter
  1. Under Parameters, select all the KML layers for Batch Input KML File, and specify the location for Output Location.
Set the parameters
  1. In the Output Data Name, insert the desired name. Click Run.
Insert desired name at the front of %NAME%
Note:
For the Batch Input KML File tool to work, retain %NAME% in Output Data Name to allow the creation of multiple geodatabases.
image.png

In the Contents pane, a layer file is displayed for each converted KML file. The images below demonstrate a successful conversion using the Batch KML To Layer tool.

Successful conversion of multiple KML files
Successful conversion of multiple KML files

Article ID:000026431

Software:
  • ArcGIS Pro 2 8 x

Receive notifications and find solutions for new or common issues

Get summarized answers and video solutions from our new AI chatbot.

Download the Esri Support App

Related Information

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options