GetPoint Method Example

This example examines the current selection and returns its screen coordinates.

Dim pLeft As Long
Dim pTop As Long
Dim pWidth As Long
Dim pHeight As Long

ActiveWindow.GetPoint pLeft, pTop, pWidth, pHeight, _
    Selection.Range
MsgBox "Left = " & pLeft & vbLf _
    & "Top = " & pTop & vbLf _
    & "Width = " & pWidth & vbLf _
    & "Height = " & pHeight