Export features into a .kmz file

You will start ArcGIS Earth and add the necessary data layers for creating the .kmz file of rivers and dams. You'll experience the versatility of ArcGIS Earth by using data from a shapefile and ArcGIS Online feature layers to create the custom .kmz file.

Start ArcGIS Earth and add data

First, you will download the data that you will use in the tutorial.

  1. Start ArcGIS Earth desktop app and if necessary, skip the tour.
    Note:

    If you don't already have ArcGIS Earth desktop app, you can get it here.

  2. On the title bar for ArcGIS Earth, click Not signed in and click Sign in.

    Sign in button for ArcGIS Earth

  3. Sign in to your ArcGIS account.

    Next, you will download a shapefile of the Colorado river basin that you will use for creating the .kmz file.

  4. Download the Colorado river basin zipped shapefile.
  5. Go to the Downloads folder or where you saved the file you just downloaded. Right-click it and choose Extract All.
  6. Browse to a folder, such as the Documents folder, and click Extract.

    Next, you will add the shapefile to ArcGIS Earth.

  7. On the toolbar, click Add data.

    Add data button

  8. Click Add Files and click Select files.

    Select files button

  9. Browse to where you unzipped the CRB_Rivers shapefile. Click the folder, click the .shp file and click Open.

    The shapefile appears on the map and ArcGIS Earth zooms to it.

    Colorado river basin shapefile added

    Note:

    The basemap in the graphics may be different from your basemap. To choose a different basemap, click the Basemap and Terrain button on the toolbar.

    Now you will add more data, but this time you will add it from ArcGIS Online.

  10. On the toolbar, click Add data and click ArcGIS Online. Click the My Content drop-down menu and choose ArcGIS Online.

    ArcGIS Online on the drop-down menu

    You want to add feature services that are on ArcGIS Online so you will create a search filter to narrow down the results to that type of data.

  11. Click the Filter button and choose Feature Service.

    Feature Service as the item type to filter

    The filter you selected is listed under the search bar.

    Feature Service filter listed

    In this case, there is only one filter, but you can set multiple filters if necessary.

  12. In the search bar, type colorado river basin and press Enter.
  13. In the search results, find Colorado River Basin Dams and Colorado River Basins.

    Search results showing the Colorado River Basin layers to add

  14. For each layer, click the Add button to add them to ArcGIS Earth.

    Add buttons on the layers

  15. Close the Add data window.

    The feature service layers display on the map.

    Feature service layers added to ArcGIS Earth

    The layers appear with default symbology. Next, you will change the style to better suit your needs.

Set display properties for layers

ArcGIS Earth allows you to change symbology for layers and set other layer properties, such as labels and layer transparency. Next, you will modify the symbology of the layers and add labels to provide descriptive information for your data.

  1. On the toolbar, click the Expand Table of Contents button.

    Expand Table of Contents button

    The Table of Contents list appears and shows the layers that you have added.

    Table of Contents showing the layers that are in ArcGIS Earth

    Currently, the Colorado River Basins layer, a polygon layer, is drawing on top of the other layers and covering them. You can rearrange the drawing order of the layers so that you can see all the layers clearly. The layers draw from the bottom up and it is recommended that you have imagery and polygons on the bottom, then lines, and then points.

  2. In the Table of Contents list, click Colorado River Basins and drag it below CRB_Rivers.

    The layer drawing order

    On the map, the layer draw order is changed and the river basins now display under the other layers.

    River basins displayed under other layers

    Next, you will change the color for the rivers to better represent those features. You can change the symbology for layers from the Table of Contents list.

  3. Right-click the CRB_Rivers layer and choose Symbology.

    The Symbology option for CRB_Rivers layer

    The Symbology – CRB_Rivers window appears.

  4. In the Symbology – CRB_Rivers window, in the Symbol Type tab, for Symbol Type, choose Location (Single Symbol).

    Set Symbol Type to Location (Single Symbol)

  5. In the Symbol Style tab, for Symbol, click the existing line symbol.

    The existing line symbol

  6. In the dialog box that appears, for Color, click the existing color patch. Under Default Color, click the blue color patch.

    The Color button and the blue color patch under Default Color

  7. Click OK twice and close the Symbology CRB_Rivers pane.

    On the map, the rivers now display in blue, a symbol more appropriate for water features.

    Rivers layer drawing in blue

    For the Colorado River Basins layer, notice that the two basins are represented with the same color. You can change the symbology so that each basin is represented by a unique color.

  8. In the Table of Contents list, for the Colorado River Basins layer, click the arrow next to it to expand it.

    The Colorado River Basins layer expansion arrow

  9. Right-click the Colorado River Basins sublayer and choose Symbology.
  10. In the Symbology window, for Style by, click the drop-down menu and choose Hu_6_Name. For Symbol Type, click the drop-down menu and choose Types (Unique Symbols).

    Colorado River Basins layer symbolized with unique symbols

  11. In the Symbology window, click the Symbol Style tab. For Layer Transparency, type 50 (or adjust the slider).

    Layer Transparency

    Note:

    Your default symbology may be different than those in the graphics.

    With a transparency set, you can see the underlying basemap while still drawing the river basin polygons.

    Transparency allows seeing basemap

  12. Close the Symbology window.

    Now that you have changed the symbology for some layers, you will add labels to add descriptive information to the map.

  13. In the Table of Contents list, expand the Colorado River Basin Dams layer.
  14. Right-click the Colorado_River_Basin_Dams sublayer, point to Labeling, and choose Enable labeling.

    Enable labeling option

    The labels for the dams appear on the map.

    Dams labeled by name

    You have made the layers look better in ArcGIS Earth. Next, you will select records and export them to a .kmz file.

Export selected records to .kmz file

Next, you will select rivers based on their name attribute to select only the Colorado River and export the selected features to a .kmz file.

  1. In the Table of Contents list, right-click the CRB_Rivers layer and choose Attribute Table.

    The Attribute Table button for the CRB_Rivers layer

    The attribute table appears.

    Attribute table for the CRB_Rivers layer

    Next you'll turn on the extent filtering and select one river feature to export in a .kmz file.

  2. Move the attribute table window so that you can see the features on the map. Scroll down the table to see the row for FID 26, one segment of the Colorado River.
  3. In the table, click Extent filtering is disabled to enable filtering. Click the row where FID is 26.

    The button and selected row are highlighted.

    Turn on extent filtering and select feature with FID = 26

    The selected feature is also highlighted on the map.

    Colorado river feature selected on map

    You have selected the feature that you want to export to a .kmz file. Next, you will export it from the attribute table.

  4. In the attribute table, on the toolbar, click the Export selected button.

    Export selected button

    The Save As dialog box appears.

  5. Browse to where you want to save the file, such as the Documents folder.
  6. For File name, type ColoRiver.

    Saving the .kmz file.

  7. Click Save.
  8. Close the attribute table and in the Table of Contents, turn off CRB_Rivers.
  9. On the toolbar, click Add data. Click Add Files, click Select files, browse to the ColoRiver.kmz file, and add it.

    The map zooms in to the river.

    Colorado River with dam labels

    As you zoom in, notice that the position of the dam labels change.

  10. Zoom in so that you can see Hoover Dam in the north, Parker Dam in the center of the river, and Morelos Dam at the southern end of the river.
    Note:

    The label for Parker Dam appears as you zoom in closer.

  11. Right-click and move the pointer to tilt the view.

    Tilted view of the Colorado River

    Next, you will select and export the three dam points to a .kmz file.

  12. In the Table of Contents, right click ColoRiver.kmz and click Zoom to layer. Open the attribute table for the Colorado River Basin Dams layer.
  13. In the table, click Extent filtering is disabled to enable filtering.
  14. Scroll through the table and select the three rows where the Name value is Hoover Dam, Parker Dam, and Morelos Dam by selecting the first row and then pressing the Ctrl key to add the other rows to the selection.

    Selected dams on the map and in the table

  15. In the attribute table, on the toolbar, click Export selected. If necessary, browse to the same folder you saved the other .kmz file to, name it dams.kmz, and click Save.
  16. Close the attribute table.
  17. Add the dams.kmz file to ArcGIS Earth. Turn off the Colorado River Basin Dams layer.

    Colorado river with three dam points

    Now you have two separate .kmz files that you will edit and work with in the next module.

You have labeled features, selected records based on their name, and exported them into .kmz files. Next, you’ll edit the .kmz file.


Edit the .kmz file

You have created two .kmz layers, one for the river segment and the other for the three dams. Next, you will edit the .kmz files to combine the river lines and dam points together into one .kmz file and further edit the geometry properties.

Group and copy .kml nodes

You will group the three dam points together to make them easier to manage.

  1. In the Table of Contents list, expand dams.kmz.

    dams.kmz layer expanded to show the three dams

    You will select the three dam features and group them together.

  2. In the Table of Contents list, click the name Hoover Dam to select it.

    Hoover Dam and its node selected in the map

    Notice on the map that the point for Hoover Dam is also selected. You will select the other dams so you can group them.

  3. In the Table of Contents list, while pressing the Ctrl key, click Morelos Dam and click Parker Dam to select them both.

    All three dams are selected.

    All three dams selected

  4. Right-click the selected group of dams and choose Group.

    Group option for the selected dams

    An item called new group appears.

    New group item added to Table of Contents

  5. Right-click the new group layer and choose Rename.

    Rename option for the new group layer

  6. Type Dams and press Enter.

    Next, you will copy the river feature and paste it into the .kml file that contains the dams so you have one file containing all the data.

  7. Expand the ColoRiver.kmz layer. Right-click the Colorado River item and choose Copy.

    Copy option for the Colorado River layer

  8. Turn off the ColoRiver.kmz layer.
  9. Right-click the Dams group and choose Paste.

    Paste option for the Dams group

    Now all the features are in one group in one .kmz layer.

    Colorado River pasted into the Dams group

  10. In the Dams group, turn on Colorado River. Turn off and on the Dams group to see that all features turn off and on with the layer.

Now the three dams and one river feature are all in the same .kmz layer. Next, you will prepare your .kmz file for sharing and share it to ArcGIS Online.


Append elevation profiles and share the .kmz file

Generate elevation profile

With the river as a separate KMZ node, you can plot the longitudinal river elevation profile.

  1. In the Table of Contents list, in the expanded Dams group, right-click the Colorado River layer and choose Elevation Profile.

    Elevation Profile on the context menu

    After a couple of minutes, the Elevation Profile window appears.

    Elevation Profile window for the Colorado River

    You will flip the elevation profile so it looks like the river profile is going downhill from left to right.

  2. In the Elevation Profile window, click the Flip direction button.

    Flip direction button

    The elevation profile for the river is flipped.

    Flipped elevation profile

    You can export the elevation profile as an image.

  3. In the Elevation Profile window, on the toolbar, click the Export image button.

    Export image button

  4. In the Export window, confirm Export as image is selected and click Export. For File name, change the name to FullElevationProfile and click Save.

    To explore the elevation profile of the river, you can move the pointer along it to see the various locations on the map.

  5. In the Elevation Profile window, move the pointer to see how the profile and the map change.

    Moving the pointer along the elevation profile

    You’ll see points being highlighted synchronously along the elevation profile in the window and the river line on the map. Next, you will export the elevation profile for the Hoover Dam area.

  6. Move the pointer to the upper stream of the elevation profile until you see the point highlighted on the map overlapping with the Hoover Dam point.

    Overlapping elevation profile point on Hoover Dam
    Note:

    The values you see on the elevation profile will reflect where you place your pointer. They may be different than those in the graphic.

  7. Press the Spacebar to lock the highlighted area.
  8. In the Export window, click the Export button and name this image HooverDamElevation. Click Save.

    Next, you will capture images of the elevation profile for the other dams.

  9. Click the elevation profile to unlock the highlighted area.
  10. On the elevation profile, move the slider until it is over the point for Parker Dam and press the Spacebar.
  11. Using similar steps, export the image of the Parker Dam profile to a file named ParkerDamElevation.
  12. Using similar steps, move the elevation profile so Morelos Dam is highlighted and save an image named MorelosDamElevation.
  13. Close the Elevation Profile window.

    Now you have four images: one of the full profile and one of each of the dams.

Embed elevation profiles

Next, you’ll insert the elevation profile images into the KMZ nodes so that they show in the pop-up window when clicking the KMZ node.

  1. In the Table of Contents list, right-click the Colorado River feature and choose Properties.
  2. In the window that appears, click the Info tab, and verify that Rich Text is selected.

    Info tab, Rich Text option selected

    Currently, the FID value and the Name text will appear when you click this feature on the map. You will edit the name of the river and then you will add the elevation profile image.

  3. For NAME, click Colorado River to make it editable and change the name to Lower Colorado River.

    Name changed to Lower Colorado River

    Next, you will add the elevation profile image.

  4. In the properties window, use the arrow keys or your pointing device to place the cursor alongside the table on the right. Then, click the Insert image button.

    Insert image button, where to locate cursor for insertion

  5. Click the Set path button, browse to where you stored the elevation profile images, choose FullElevationProfile, and click Open.

    The elevation profile appears below the table entries.

    Elevation profile added to the pop-up window

  6. Close the properties window.
  7. In the Table of Contents list, click the Colorado River node to open the pop-up and see the elevation profile for the river.
  8. Close the pop-up window.
  9. For each of the dam nodes, performing the following steps:
    • In the Table of Contents, right-click the dam’s node and choose Properties.
    • Click the Info tab and choose Rich Text.
    • Click in the table of attributes and use the keyboard arrows or your pointing device to place the cursor on the right side of the table.
    • Click the Insert image button.
    • Browse to the dam’s elevation profile image and add it below the table.

    To see the elevation profile for a dam, click the dam on the map or its node in the Table of Contents to open the pop-up window, then scroll down.

    You have completed all the edits, and next, you’ll save the .kmz layer.

  10. In the Table of Contents list, right-click Dams.kmz and choose Save as.

    Save the .kmz file.

  11. In the Save as window, click Set path and for File name, choose the existing file Dams.kmz and click Save. When asked if you want to replace the existing file, click Yes.

    Save as window

  12. In the Save as window, click OK.

    The edits you made are saved to the existing .kmz file.

    Note:

    To save the edits in a new file, type a new file name. To point the existing layer to the newly created .kmz file, check the Replace the layer in TOC once exported box.

    Next, you will apply a 3D effect. With the default elevation exaggeration, you may not see the topography along the Lower Colorado River very clearly. You will set the elevation exaggeration higher, and when you tilt the view, you’ll be able to see the river in a more intuitive way.

  13. On the toolbar, click the Environment Effects button.

    Environmental Effects button

  14. Click Terrain Exaggeration and move the slider or type 80.
  15. Tilt the view.

    View tilted to see elevation exaggeration

    The terrain is more visible.

  16. Close the Terrain Exaggeration window.

Share the .kmz file

Next, you will share your .kmz file to your ArcGIS organization account so that others in your organization can access it.

  1. In the Table of Contents list, right-click the Dams.kmz layer and choose Share to.

    Share to option

    The Share KML to Portal window appears.

  2. For Summary, type or copy and paste the following: This KMZ file contains the Lower Colorado River and three dams along it, Hoover Dam, Parker Dam, and Morelos Dam.
  3. For Tags, click the Add tag(s) button. Type Lower Colorado River and press the Tab key.
  4. For Portal Folder, click the drop-down menu and choose Create new folder.
  5. Replace the text, New folder, with KMZ Files.
  6. For Share with, click the box next to Organization.

    Share KML to Portal dialog box filled out

  7. Click Share.

    Once the item is shared, a message will appear stating that it was successful. The .kmz file you updated on your computer is now hosted in ArcGIS Online. You can view the item in your ArcGIS organization and manage it from there.

  8. In the Successfully shared window, click Manage the portal item.

    Manage the portal item

    The item details page for your .kmz file hosted in ArcGIS Online opens in a browser window.

    Item details page for the .kmz file

    On the item details page, you can edit the Description and Terms of Use sections and manage how the item is shared. Currently, the item is shared in your organization only, but you could share it publicly so anyone outside of the organization can access it too.

  9. Return to ArcGIS Earth and close the Successfully shared message.

    The .kmz file is now shared to ArcGIS Online and others within your organization can access and use the layer in their maps and apps.

In this tutorial, you loaded data from multiple sources into ArcGIS Earth, selected features, and added them to a .kmz file. Once you created the .kmz file, you edited it to include both river and dam features, appended elevation profiles, and shared it to ArcGIS Online. In a few quick steps, you created a file that contains information about rivers and dams that others within your organization can use in their maps and analyses.