Description
When attempting to convert and display individual or multiple polygons or lines using the Map to KML or Layer to KML tool, labels for the polygons or lines do not appear in Google Earth.
Cause
This is a known limit. Google Earth only displays labels for point features (placemarks). To display labels for line or polygon features in Google Earth, midpoints or centroids for those feature classes must be created as a point layer in ArcMap and imported as a separate layer to Google Earth.
Note:
KML uses the WGS84 coordinate system and meters for the unit of measurement. All elevation values are assumed to be in meters when creating KML.
Solution or Workaround
For Advanced licenses, use the Feature To Point tool
- Create points for the line or polygon data using the Feature To Point tool. Use the polygon/line layer as the Input Features, and determine the location for the Output Feature Class. Click OK.
- Label the point feature class with the desired field (right-click the layer, and select Label Features).
Note:
The Label Field can be changed by navigating to the Labels tab in Layer Properties.
- Use the Map to KML tool to convert the data to a KML or KMZ file, which can be viewed in Google Earth.
For Basic and Standard licenses, users do not have access to the Feature To Point tool. As a secondary option, follow the steps below.
- Open the attribute table of the polygon layer, and add two new fields, Longitude and Latitude (Table Options > Add Field). Ensure that the field is set to Double.
- Right-click the Longitude field > Calculate Geometry > X Coordinate of Centroid.
- Right-click the Latitude field > Calculate Geometry > Y Coordinate of Centroid.
- Export the attribute table to a new file. Click Table Options > Export. Add the table to the Table of Contents.
- Right-click the table > Display XY Data.
- Specify the X and Y fields.
- To save the event layer, right-click the event layer > Data > Export Data, as a shapefile or feature class.
- Label the shapefile or feature class with the desired field.
- Use the Map to KML tool to convert the data to a KML or KMZ file, which can be viewed in Google Earth.