Поделиться через


DragEventArgs.GetPosition Method

Microsoft Silverlight will reach end of support after October 2021. Learn more.

Returns a drop point that is relative to a specified UIElement.

Namespace:  System.Windows
Assembly:  System.Windows (in System.Windows.dll)

Syntax

'Declaration
Public Function GetPosition ( _
    relativeTo As UIElement _
) As Point
public Point GetPosition(
    UIElement relativeTo
)

Parameters

Return Value

Type: System.Windows.Point
A drop point that is relative to the element specified in relativeTo.

Remarks

To obtain a coordinate in the coordinate space of the Silverlight content area, pass nulla null reference (Nothing in Visual Basic) for relativeTo.

Version Information

Silverlight

Supported in: 5, 4

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.