Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations IDS on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Getting Autocad Dimension Data

Status
Not open for further replies.

AlexDring

Mechanical
Dec 31, 2002
117
Is there a way to extract the value of a acad dimension with some sort of getvar or getval?
 
Replies continue below

Recommended for you

With EntGet and Car or Cadr perhaps.
 
Hi AlexDring...

This function I did You can help You:

(defun get:value (/ dim-ent value)
(setq dim-ent (vlax-ename->vla-object
(car (entsel "\nSelect object dimension: "))
)
)
(if (vlax-property-available-p dim-ent "measurement")
(progn
(setq value (vlax-get-property dim-ent "measurement"))
(prompt (strcat "\nDimension value is: "
(rtos value 2 (getvar "dimdec"))
)
)
) ;_progn
(prompt
"\nThis object don't have this property. Try again..."
)
) ;_if
(princ)
) ;_defun

FORO: Un saludo de SpeedCAD... ;)
CHILE
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor