Using Ax*Control's in a custom dialog that runs within ArcMap.

When I right-click on a feature layer in the AxTOCControl, and go to display the context menu, is it possible to display and make usable:
1) The ArcMap feature layer context menu:
2) A custom menu, but with one or more of the existing commands e.g.:
esriCore.LayerContextMenuItems, subtype:9 (Layer_Properties).

The crux of the issue is that the existing menu items don't enable; presumably because I'm not giving the hook they expect, or specifying the selected layer in the way they expect.

I have seen the examples, but all show creating custom commands, with a custom solution to use the map control custom property to store the selected layer. I've tried using that approach with the existing commands, but unsuprisingly it doesn't work.

If you can't use the existing ArcMap TOC context menu commands w/ the AxTOCControl, what is the recommended way of providing a similar context menu for the AxTOCControl - rebuilding from scratch in code, including the property sheets and pages ?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.