erikadade

Add custom layer context menu item in specific MXD

Discussion created by erikadade on Apr 9, 2014
I would like to add custom tools/menus to the default context menus for group layers, raster layers, feature layers and tables in the TOC, but only for a specific ArcMap document.  I have implemented a command in VB.NET to add the items on OpenDocument events, but then it applies to every MXD while the component is registered.  Is there a way to limit the behavior to a specific document? 

An alternative may be to define custom layers. Can a custom class inherit from GroupLayer, RasterLayer, etc (instead of BaseDynamicLayer) and then add to the default context menu inherited from that class?

Thanks for any advice!

Outcomes