Jump to content

Recommended Posts

Posted

hi all

 

i want to be able to change a dimension to read "eq" or "equal" etc just by one click. i expect this is possible but i don't know how to do it.

 

at the moment i spend a lot of time typing "eq" when making lighting layouts and general setting out drawings. i would like to automate it, and have no preference between button or command.

 

if possible, change multiple dims together would also be handy.

 

thanks for any help

Posted

Try the following:

(defun c:dimeq ( / e i s )
   (if (setq s (ssget "_:L" '((0 . "*DIMENSION"))))
       (repeat (setq i (sslength s))
           (setq e (entget (ssname s (setq i (1- i)))))
           (entmod (subst '(1 . "eq") (assoc 1 e) e))
       )
   )
   (princ)
)

Posted

Lee Mac - the original and still the finest!

thank you, it is perfect for my needs. one of these days i will donate to your website. legend!

  • 4 months later...
Posted

right, so this works like a charm, very pleased thanks lee!

 

now i want to do the opposite!

is it possible to remove dimension override text with a one-click function?

 

either select lots of dims, input command, and all dims are back to 'natural' state

or failing that, input command, pick a dim, it reverts to 'natural'

 

thanks all, most appreciated!

Posted

Please adjust this line:

(entmod (subst '(1 . "[color=magenta]<>[/color]") (assoc 1 e) e))   ;replace "eq" with "<>"

Posted

There are several options Stuart. You could use the routine that Lee gave you and change the text that it uses to either an empty string i.e. "" or the less than-greater than "".

 

as in

(entmod (subst '(1 . "") (assoc 1 e) e))

or

(entmod (subst '(1 . "<>") (assoc 1 e) e))

 

Or alternatively the standard autocad command "dimedit" => "new" => "OK"

Posted

or even

 

command: Dim

n

(select all)

 

EDIT: oops (look up ↑)

Posted

great chaps, thank you. i prefer the option, that makes sense to me.

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...