Selection extension

Description

This sample demonstrates how to modify the map page by adding a menu item. When the menu item is selected, the extension pushes a context menu onto the map page, so that the map page takes on a different user interface (UI). This UI allows you to select features and perform specific actions on them. You can cancel out of the custom UI by pressing the left soft key to get back to the default map context menu.

Prerequisites

Product: ArcGIS for Windows Mobile

Platforms: Windows Mobile 5/6

Requirements: Visual Studio 2008 with SP1, .NET Compact Framework 3.5

How to use

  1. Open the project in Visual Studio 2008. Learn how to set up your development machine.
  2. Before you compile the project, open the SelectionExtension.cs file and replace the Road Signs string with a layer name from your mobile project. This is the layer from which the Selection extension will select features.
  3. Compile the project and deploy the assembly to your mobile device or emulator. Read more information about deployment.
  4. Build and deploy the Mobile Project assembly file (included with the sample project) to the <ArcGIS Mobile installation path>\bin\Extensions folder on your desktop where you'll author your mobile project with the Mobile Project Center application.
  5. In Mobile Project Center, add the extension to your project on the Capabilities tab.
  6. Deploy your mobile project to your Windows Mobile device or emulator. Get more details on deployment.
  7. Start the out-of-the-box mobile application.
  8. Tap to open the mobile project.
  9. On the Select Task page, tap the View Map task.
  10. On the View Map page, tap the right soft menu. A new menu item, Selection Mode, is at the top.
  11. Tap Selection Mode. The map page displays a different set of UI elements, as defined by the customized MapPageContext. By default, the active map action is Selection map action, allowing you to select features.
  12. Select features, and from the right soft menu, view operations you can perform on them.
  13. View and edit attributes for selected features or add them to the work list.

Where to get the sample

The sample is available for download from ArcGIS.com.

1/7/2015