Jump to content

Recommended Posts

Posted

Hi,

 

i have a bunch of aligned dimensions in a drawing that i'd like to change to linear dimenions generally. Is there an easy was to do this or do i simply need to delete all the aligned dimensions and redraw them as linear dimensions?

Posted

Here is some quick-n-dirty code example to get you started.

 

(defun convertAlignedDimToVer ( / alDimEname alDimElist pt1 pt2 distFact dimTxtIP x1)

 

(setq alDimElist (entget (setq alDimEname (car (entsel "\nSelect (click on) aligned dim: ")))))

(setq pt1 (cdr (assoc 13 alDimElist)))

(setq pt2 (cdr (assoc 14 alDimElist)))

(if (

(setq distFact -1)

(setq distFact 1)

)

(setq dimTxtIP (list (+ x1 (* 2.0 distfact)) (/ (+ (cadr pt1) (cadr pt2)) 2.0)))

 

(command "dim" "ver" pt1 pt2 dimTxtIP "")(command)

(entdel alDimEname)

 

)

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...