ade_dwggetsetting

AutoCAD Map 3D AutoLISP

Up a level
ade_dwggetsetting
 
 

Gets a drawing setting value.

(ade_dwggetsetting dwg_id setting)

Returns the value of the given drawing setting or nil.

dwg_id Drawing ID (real)
setting Drawing setting name (string).
See Drawing Setting Names below
Drawing Setting Names
Setting Name Return Value
dwgname Drawing name (string); a path alias and file name, such as "myfiles:\\mydwg.dwg
dwgdesc Drawing description (string)
t_scale Simple transform scale (real.
For example, 1.2 = 120%
t_rotate Simple transform rotation direction. Value depends on the AutoCAD ANGDIR setting (real). Values:
0 = counterclockwise
1 = clockwise
t_xoffset Simple transform X offset (real)
t_yoffset Simple transform Y offset (real)
t_apply Flag value (integer). Values:
1 = apply all simple transformations defined for the given drawing
0 = do not apply transformations
saveback Save back coordinates, a sequence of corner points, in this order: lower left, lower right, upper right, upper left, separated by "."

The following code gets the name of the first drawing in the list of attached drawings:

(setq dwg_id (car (ade_dslist)))
(ade_dwggetsetting dwg_id "dwgname")

The return value is a drawing path name, for example,

"c:\\drawings\\mydwg.dwg"