Aarcgisprosdk10.8 Release
5ac5058d创建于 2020年2月21日历史提交
文件最后提交记录最后更新时间
6 年前
6 年前
9 年前
6 年前
6 年前
README

Save a layer file in a MapControl application

This sample demonstrates how to create and save a layer file in a stand-alone ArcGIS Engine application. In addition to providing the ability to save layer files, this sample also implements a context menu that opens when you right-click a layer in the application's table of contents (TOC). This context menu hosts two commands: Save the current layer as a layer file and Remove the current layer from the map.

Language:              C#, VB
Subject:               Controls
Organization:          Esri, http://www.esri.com
Date:                  10/17/2019
ArcObjects SDK:        10.8
Visual Studio:         2017, 2019
.NET Target Framework: 4.5

Resources

Usage

  1. Start Visual Studio, open the solution file, and build the project.
  2. Press F5 to run the MapControl application.
  3. Use the AddData command to add a dataset to the map, or as an alternative, use Add MapDocument to add an existing map document to the map.
  4. Right-click a layer in the TOC to open the context menu.
  5. Click the Create Layer File command to save the current layer with its current renderer as a layer file.
  6. Use the Load Layer File command to load the new layer to the map.

See Also

How to save a layer file


Licensing

Development licensing Deployment licensing
Engine Developer Kit Engine
ArcGIS Desktop Basic
ArcGIS Desktop Standard
ArcGIS Desktop Advanced