Save a layer file in a MapControl application
|
| Development licensing |
Deployment licensing |
| Engine Developer Kit |
Engine Runtime |
| ArcView |
ArcView |
| ArcEditor |
ArcEditor |
| ArcInfo |
ArcInfo |
How to use
See Using the samples for help on compiling, setting up the debugger, and running the sample (either an exe or dll).
- Open the solution using Visual Studio 2005.
- Build the solution.
- Press F5 to run the MapControl application.
- Use the AddData command to add a dataset to the map, or as an alternative, use the Add MapDocument to add an existing MapDocument to the map.
- Right-click a layer in the TOC to pop up the context menu.
- Click the Create Layer File command to save the current layer with its current renderer as a layer file.
- You can use the Load Layer File command to load the new layer to the map.
| SaveLayerFileCmd.cs
|
Save layer files command. |
| RemoveLayerCmd.cs
|
Remove layer command. |
| LoadLayerFileCmd.cs
|
Load layer command. |
| CreateNewDocument.cs
|
Create new MapDocument command. |
| ContextMenuClass.cs
|
Implementation file of the ContextMenu used by the application. |
| frmMain.cs
|
Application's main dialog box form. |
Download the
C# files
| SaveLayerFileCmd.vb
|
Save layer files command. |
| RemoveLayerCmd.vb
|
Remove layer command. |
| LoadLayerFileCmd.vb
|
Load layer command. |
| CreateNewDocument.vb
|
Create new MapDocument command. |
| ContextMenuClass.vb
|
Implementation file of the ContextMenu used by the application. |
| frmMain.vb
|
Application's main dialog box form. |
Download the
VB.NET files
Download the files for all languages
See Also:
How to save a layer file