ArcObjects Library Reference (Controls)  

IHookHelper.ActiveView Property

Active view of hooked control or application.

[Visual Basic .NET]
Public ReadOnly Property ActiveView As IActiveView
[C#]
public IActiveView ActiveView {get;}
[C++]
HRESULT get_ActiveView(
  IActiveView** ppActiveView
);
[C++]

Parameters

ppActiveView [out, retval]

  ppActiveView is a parameter of type IActiveView

Product Availability

Available with ArcGIS Engine.

Description

The IActiveView of the hook passed to the ICommand::OnCreate event. The ActiveView is returned regardless of whether the hook is a MapControl, PageLayoutControl, ToolbarControl (with a 'buddy' MapControl or PageLayoutControl) or ArcMap.

Errors Returned

1058 800A0422: The supplied hook does not implement ICommandHook. 

1059 800A0423: The supplied hook is not a valid object. 

1060 800A0424: The supplied hook is not valid. 

1061 800A0425: IARPageLayout::get_InternalObject failed. 

1062 800A0426: IARMap::get_InternalObject failed. 

See Also

IHookHelper Interface