Jump to content

Recommended Posts

Posted

We are running autocad Mep 2013...I have a lisp routine on my computer that allows me to edit multiple lines of text by just hitting enter and it moves to the next line...But I tried to install this on a new co-workers machine and it doesn't seem to be working...The error message she gets is "no function definition ACET-ERROR-INIT".........What could be causing this?....The lisp routine I was using is as follows.....And is there maybe an easier way we could be doing this? Thanks, Jess

 

;; DESCRIPTION

;; The TEDIT command provides a single command for editing all

;; forms of annotation objects.

;;

;; ----------------------------------------------------------------

 

(defun C:TEDIT (/ noll filter ss idx ename elist kind)

;; remove objects on locked layers from ss

(defun noll (ss / i d ename)

(setq i 0

d 0 )

(while (and ss

(setq ename (ssname ss i)) )

(if (acet-layer-locked (cdr (assoc 8 (entget ename))))

(progn

(ssdel ename ss)

(setq d (1+ d))

)

(setq i (1+ i))

)

)

(if (/= 0 d)

(princ (acet-str-format "%1 %2 on a locked layer.\n"

d

(if (

)

ss

)

 

(acet-error-init '(("CMDECHO" 0) T))

 

;; make object filter

(setq filter (list

(cons 410 (if (and (= 0 (getvar "TILEMODE"))

(/= 1 (getvar "CVPORT")) )

"Model"

(getvar "CTAB") ) )

'(-4 . "

'(0 . "TEXT,MTEXT,RTEXT,ARCALIGNEDTEXT,DIMENSION,ATTDEF")

'(-4 . "

'(0 . "INSERT")

'(66 . 1)

'(-4 . "AND>")

'(-4 . "OR>") ) )

 

;; pick objects

(if (not (and (= 1 (logand 1 (getvar "PICKFIRST")))

(setq ss (noll (ssget "_I" filter))) ) )

(setq ss (ssget "_:L" filter))

)

 

;; process ss

(if ss

(progn

(setq idx -1)

(acet-ui-progress "Editing:" (sslength ss))

(sssetfirst)

(redraw)

(while (setq ename (ssname ss (setq idx (1+ idx))))

(redraw ename 3)

(redraw)

(setq elist (entget ename)

kind (cdr (assoc 0 elist)) )

(cond

((or (= kind "TEXT")

(= kind "MTEXT")

(= kind "DIMENSION")

(= kind "ATTDEF") )

(command "_.DDEDIT" ename "") )

((= kind "INSERT")

(command "_.DDATTE" ename) )

((= kind "ARCALIGNEDTEXT")

(command "_.ARCTEXT" ename) )

((= kind "RTEXT")

(if (or (= 'USUBR AcetRText:edit) (load "rtext" nil))

(AcetRText:edit elist)

(princ "TEDIT: Cannot edit RTEXT objects.\n")

)

)

)

(entupd ename)

(redraw ename 4)

(acet-ui-progress -1)

)

(acet-ui-progress)

(sssetfirst nil ss)

)

)

 

(acet-error-restore)

(princ)

)

 

(acet-autoload2 '("Rtext.lsp" (AcetRText:edit ent)))

(princ)

Posted

We'll give this a *bump* and see if it attracts any interest. I should warn you that there are code posting guidelines that you may be asked to follow in the future. Good luck.

Posted
...The error message she gets is "no function definition ACET-ERROR-INIT".........What could be causing this?....The lisp routine I was using is as follows.....And is there maybe an easier way we could be doing this? Thanks, Jess

 

It throw an error because your co-worker does not have the Express Tools installed on her machine .

Posted

I'm sorry about the code posting...I'll make sure to look at the guidelines...I had a feeing I was doing something wrong.

As for my post..I guess I screwed that up too.....I didn't realize it now works with the express tools.....That lisp routine was really old and we shouldn't be using it anymore anyways....

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