Pauses for user input of a distance
(getdist [pt] [msg])
The user can specify the distance by selecting two points, or by specifying just the second point, if a base point is provided. The user can also specify a distance by entering a number in the AutoCAD current distance units format. Although the current distance units format might be in feet and inches (architectural), the getdist function always returns the distance as a real.
The getdist function draws a rubber-band line from the first point to the current crosshairs position to help the user visualize the distance.
The user cannot enter another AutoLISP expression in response to a getdist request.
A real number. If a 3D point is provided, the returned value is a 3D distance. However, setting the 64 bit of the initget function instructs getdist to ignore the Z component of 3D points and to return a 2D distance.
(setq dist (getdist))
(setq dist (getdist '(1.0 3.5)))
(setq dist (getdist "How far "))
(setq dist (getdist '(1.0 3.5) "How far? "))
The initget function. The getxxx Functions in the AutoLISP Developer's Guide.