PDA

View Full Version : Edit regular text in a Block



cthomas.40428
2005-11-28, 04:46 PM
I need to know how to edit regular text within a block that has attributes? I have looked at the Block Attribute Manager and tried ATTEDIT. These just edit the attribute information. I need to know how to edit regular AutoCAD text that is part of a block without having to explode the block to change it. Can anyone help me with this? Email me at Cthomas@CBI.com

Thanks for your help

Opie
2005-11-28, 04:55 PM
Please note I have *moved* this thread from the New Forum Users (http://forums.augi.com/forumdisplay.php?f=47) Forum to this one as I believe it would be better served here.

Below snippet is from the small print on the Forum General (http://forums.augi.com/forumdisplay.php?f=44) page -

<snip>
New to the Forums? This is the place to experiment with the posting editor and learn how to interact with our forums. Please experiment here with forum features and commands.
</snip>

Thanks,

Richard
Forum Moderator

Opie
2005-11-28, 05:05 PM
Which version of AutoCAD are you using? Depending on the version, have you tried the REFEDIT command? This will allow you to modify the block without exploding it.

cthomas.40428
2005-11-28, 05:18 PM
Sorry, I am using AutoCAD 2004.

cthomas.40428
2005-11-28, 05:22 PM
I tried the REFEDIT command and that did excatly what I wanted it to do.

Thanks for the help.

cadop_1_uk
2005-11-30, 08:28 AM
I found this lisp program + dcl - modbtxt some time ago. One of the drawbacks is that it needs to load program everytime to run.


;;MODBKTXT.LSP
;;
;;Edit Text enbedded in a Block using a dialog box interface.
;;
;;(Need to load program everytime to run).
;;
(defun C:reset ()
(setq flg 1)
(done_dialog)
)

(setq dcl_id (load_dialog "MODBKTXT.DCL"))
(while
(setq bltxt (nentsel "\nSelect Block Text to modify: \n<Return> to end."))
(setq entdata (entget (car bltxt)) btxt (cdr (assoc 1 entdata)) ostr btxt)
(setq flg 0)
(if (not (new_dialog "MODBKTXT" dcl_id)) (exit))
(set_tile "btxt" btxt)
(mode_tile "btxt" 2)
(action_tile "btxt" "(setq btxt $value)")
(action_tile "accept" "(done_dialog)")
(action_tile "cancel" "(reset)")
(start_dialog)
(if (/= flg 1)
(progn
(entmod (subst (cons 1 btxt)(assoc 1 entdata) entdata))
(if (setq bltxt (car (reverse (cadddr bltxt)))) (entupd bltxt))
)
)
)
(unload_dialog dcl_id)
(setq bltxt nil entdata nil btxt nil flg nil dcl_id nil)


dcl file -


MODBKTXT : dialog {
label = "Modify Embedded Attributes and Text" ;
spacer_1 ;
: text {
label = "Edit Block Text String:" ;
}
: edit_box {
fixed_width = true ;
key = "btxt" ;
width = 40 ;
}
spacer_1 ;
ok_cancel ;
}


Put both files in your Autocad support directory.

Hope it helps