Well I have the target.
Perhaps this will work for other languages as it uses setvars.
It seems the Distance (or Z value in a 2d dwg) is the z value of the viewctr tanslated to display.
Since the Center of the display is the target, this makes sense.
The viewctr value is reliable (updates with pan and zoom)
In a 2d drawing you will find the x and y of the target are the x and y of the viewctr translated to world.
This property gives an updated Target in Wcs
Property Get VT() As Variant 'Target 'no update
'This gives an updated Target in Wcs
Dim Tar(2) As Double
Dim C, Cen, dir
Dim Dist As Double
C = ThisDrawing.GetVariable("viewctr")
Cen = ToWcs(C)
dir = VD
C = UToD(C)
Dist = -C(2)
Tar(0) = Cen(0) + Dist * dir(0)
Tar(1) = Cen(1) + Dist * dir(1)
Tar(2) = Cen(2) + Dist * dir(2)
VT = Tar
End Property
Function ToUcs(Pt As Variant) As Variant
ToUcs = ThisDrawing.Utility.TranslateCoordinates(Pt, acWorld, acUCS, False)
End Function
Function ToWcs(Pt As Variant) As Variant
ToWcs = ThisDrawing.Utility.TranslateCoordinates(Pt, acUCS, acWorld, False)
End Function
Function UToD(Pt As Variant) As Variant
UToD = ThisDrawing.Utility.TranslateCoordinates(Pt, acUCS, acDisplayDCS, 0)
End Function
Function WToD(Pt As Variant) As Variant
WToD = ThisDrawing.Utility.TranslateCoordinates(Pt, acWorld, acDisplayDCS, 0)
End Function