ArcObjects Library Reference (Display)  

IScreenDisplay.TrackPan Method

Interactively pans the screen.

[Visual Basic .NET]
Public Sub TrackPan ( _
)
[C#]
public void TrackPan (
);
[C++]
HRESULT TrackPan(
void
);

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Remarks

There are two approaches to panning - this method, and the group PanStart, PanMoveTo, and PanStop.  This method is the easiest to use as it takes care of all the mouse events and refreshing the display when pan is complete. 

Call this method in the mouse down event and make certain you have a reference to the correct ScreenDisplay object.  For example, if you are in layout view and you want to pan just the focus map, do not use the ScreenDisplay object associated with IMxDocument::ActiveView.  Instead, get the focus Map via IMxDocument::FocusMap, and then get its ScreenDisplay

See Also

IScreenDisplay Interface | IScreenDisplay.PanMoveTo Method | IScreenDisplay.PanStop Method | IScreenDisplay.PanStart Method