This document is archived and information here might be outdated.  Recommended version.


IPageLayoutControlEvents.OnAfterDraw Event (ArcObjects .NET 10.6 SDK)
ArcObjects Library Reference (Controls)  

IPageLayoutControlEvents.OnAfterDraw Event

Fires after the PageLayoutControl draws a specified view phase.

[Visual Basic .NET]
Public Event OnAfterDraw As OnAfterDrawEventHandler
[C#]
public event OnAfterDrawEventHandler OnAfterDraw
[C++]
HRESULT OnAfterDraw(
  VARIANT Display,
  long viewDrawPhase
);
[C++]

Parameters Display [in]
Display is a parameter of type VARIANT viewDrawPhase [in]
viewDrawPhase is a parameter of type long

Product Availability

Available with ArcGIS Engine.

Description

The OnAfterDraw event is fired after a specified phase has been drawn and is based upon the IActiveViewEvents::AfterDraw event. You must query interface for the IDisplay interface and base the viewDrawPhase on the esriViewDrawPhase constants.

Remarks

In some circumstances there maybe a need to execute some code after each individual element in a PageLayout has drawn. To do this you need to set the IViewManager::VerboseEvents property to true and use the IActiveViewEvents::AfterItemDraw event.

[C#]
IViewManager viewManager=(IViewManager) axPageLayoutControl1.PageLayout;
viewManager.VerboseEvents=true;
[Visual Basic .NET]
Dim pViewManager As IViewManager
pViewManager=AxPageLayoutControl1.PageLayout
pViewManager.VerboseEvents=True

See Also

IPageLayoutControlEvents Interface