Public Class Button1 Inherits ESRI.ArcGIS.Desktop.AddIns.Button Public Sub New() End Sub Protected Overrides Sub OnClick() ZoomToActiveLayerInTOC(TryCast(ArcMap.Application.Document, IMxDocument)) End Sub Protected Overrides Sub OnUpdate() Enabled = My.ArcMap.Application IsNot Nothing End Sub End Class
ZoomToActiveLayerInTOC,
ArcMap.and
IMxDocument