Custom ImageCombo ToolControl

Last Modified:05/23/2000

The Custom ImageCombo sample shows how to create a custom ImageCombo toolcontrol using Visual Basic. When an image item is selected in this Custom ImageCombo, the ArcMap feature selection color is changed.

The class for CustImageCombo implements the ICommand and IToolControl interfaces. To create any type of window control in Visual Basic for use in ArcInfo, you need to implement IToolControl. Since the ImageCombo will be a command item in ArcMap, you need to implement the ICommand interface.

How to use:
  1. Browse for and select the CustomImageCombo.dll using the 'Add From File' button on the Customize dialog.
  2. From the 'Developer Samples' command category, drag the 'Custom ImageCombo' command to any toolbar.
  3. Add a layer in ArcMap and select some features. Test Custom ImageCombo toolcontrol by selecting an item in the image combobox. When an item is selected, the selection color for the layer should change.


Difficulty: Intermediate

Visual Basic
File Description
frmImageCombo.frm Form that has VB ImageCombo.
CustImageCombo.cls Class file that implements IToolControl.
modPublicVars.bas Module file that declares public variables.
CustomImageCombo.vbp The project file for the custom ImageCombo.
CustomImageCombo.dll The compiled project.

Key Interfaces: IToolControl