This document is archived and information here might be outdated. Recommended version. |
ArcObjects namespaces > Controls > ESRI ArcGIS Controls > Interfaces > IP > IPageLayoutControlDefault Interface > IPageLayoutControlDefault.LocateFrontElement Method (ArcObjects .NET 10.4 SDK) |
Locates an element at the given page co-ordinates. If more than one element is at the location the element nearest the front is returned.
[Visual Basic .NET] Public Function LocateFrontElement ( _ ByVal pageX As Double, _ ByVal pageY As Double, _ [ByVal Tolerance As Double] _ ) As IElement
[C#] public IElement LocateFrontElement ( double pageX, double pageY, double Tolerance );
Optional Values
[C++]
HRESULT LocateFrontElement(
double pageX,
double pageY,
double Tolerance,
IElement** element
);
[C++]
Parameters pageX [in] pageX is a parameter of type double pageY [in] pageY is a parameter of type double Tolerance [in, optional, defaultvalue(0)] Tolerance is a parameter of type double element [out, retval]
element is a parameter of type IElement
LocateFrontElement is typically used within the IPageLayoutControlEvents::OnMouseDown event to retrieve an element at the given page coordinates. If more than one element exists at the given page coordinates, the element located at the front is returned.
IPageLayoutControlDefault Interface | IPageLayoutControlDefault.AddElement Method | IPageLayoutControlDefault.FindElementByName Method