Skip to content
Branch: master
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
CSharp
VBNet
ReadMe.xml
Readme.html
Readme.md

Readme.md

Layer property page and property sheet

A property sheet is a dialog box that contains one or many property pages. Each property page on the property sheet contains controls to view and allow users to interact with objects by changing the values of their properties without writing code.
 
This sample shows how to implement and register a custom layer property page (LayerVisibilityPage class) for ArcGIS Desktop in .NET. This property page toggles visibility of the target layer. It also includes a custom command (SimpleLayerPropertiesCmd class) showing how to display a property sheet with a selective number of property pages.
Language:              C#, VB
Subject:               Framework
Organization:          Esri, http://www.esri.com
Date:                  11/17/2017
ArcObjects SDK:        10.6
Visual Studio:         2015, 2017
.NET Target Framework: 4.5

Resources

Usage

Implement and register a custom layer property page

  1. Open and compile the sample project in Visual Studio. Set up a debug application if needed.
  2. Open ArcMap, ArcScene, or ArcGlobe. The custom layer property page works in all of these applications since it is registered in the appropriate layer property page component categories.
  3. Add a layer to the application.
  4. Display the layer context menu by right-clicking the layer and selecting Properties. The Properties dialog box appears.
  5. Activate the custom property page by clicking the Layer Visibility (C#) or Layer Visibility (VB.NET) tab.
  6. The visibility is controlled by two radio buttons on the page. Toggle visibility to enable the Apply button in the dialog box.
  7. Click the Apply or OK button to commit the change. The TOC and display are refreshed to reflect the change you made with the custom property page.
  8. Close the Properties dialog box.

Add the custom command (SimpleLayerPropertiesCmd) that displays the simplified layer property sheet

  1. Click the Customize menu, and click Customize Mode. The Customize dialog box appears.
  2. Click the Toolbars tab and select Context Menus.
  3. Expand and scroll down to Feature Layer Context Menu, and click to expand the menu.
  4. Click the Commands tab, and drag and drop the Simple Layer Properties (C#) or Simple Layer Properties (VB.NET) command from the .NET Samples category onto the Feature Layer Context Menu.
  5. Close the dialog box.
  6. Click the Simple Layer Properties command you just added. The layer context menu displays. The simplified Properties dialog box only shows the Layer Visibility and Symbology pages.
  7. If necessary, clean up to remove the custom command by resetting the Feature Layer Context Menu in the Customize dialog box.

Licensing

Development licensing Deployment licensing
ArcGIS Desktop Basic ArcGIS Desktop Basic
ArcGIS Desktop Standard ArcGIS Desktop Standard
ArcGIS Desktop Advanced ArcGIS Desktop Advanced
You can’t perform that action at this time.