Author Topic: Editing Block Text Font???  (Read 4656 times)

0 Members and 1 Guest are viewing this topic.

M-dub

  • Guest
Re: Editing Block Text Font???
« Reply #15 on: November 30, 2005, 03:14:45 PM »
<scratching head>

could you send a copy of the block?

Bob Wahr

  • Guest
Re: Editing Block Text Font???
« Reply #16 on: November 30, 2005, 03:20:29 PM »
I want to play too!

Murphy

  • Guest
Re: Editing Block Text Font???
« Reply #17 on: November 30, 2005, 06:22:30 PM »
Just so you know, I am really fighting the urge to post a very crude reply.
 :lmao:

MP

  • Seagull
  • Posts: 17750
  • Have thousands of dwgs to process? Contact me.
Re: Editing Block Text Font???
« Reply #18 on: November 30, 2005, 06:36:28 PM »
Let me applaud your self control Mr. Murphy.
Engineering Technologist • CAD Automation Practitioner
Automation ▸ Design ▸ Drafting ▸ Document Control ▸ Client
cadanalyst@gmail.comhttp://cadanalyst.slack.comhttp://linkedin.com/in/cadanalyst

M-dub

  • Guest
Re: Editing Block Text Font???
« Reply #19 on: November 30, 2005, 09:52:52 PM »
Let me applaud your self control Mr. Murphy.

:lmao:

hudster

  • Gator
  • Posts: 2848
Re: Editing Block Text Font???
« Reply #20 on: December 01, 2005, 04:04:32 AM »
here is a very handy lisp I found on the internet. (I don't know who wrote it is anyone does let me know and I'll give them credit.)

This should do what you want to do.

Code: [Select]
; Change Attribute Properties en masse
;; A series of routines for changing attribute properties on a mass of attributes.
;; Can change each proprty, i.e. the layer, color, style, layer etc of many attributes at once.
;;
;; Also a routine to change attribute text to upper case.
;;
;; Another to transfer data from one attribute to another. Handy if you are updating or
;; replacing blocks with a new version, i.e. line number racetrack blocks. Also copies from
;; text to attribute but not from attribute to text.
;;
;; Another routine if you drawing piping GA's using line numbers for layer names. Get the
;; layer name from an object and paste into the attribute in a line number racetrack block.
;;


;;;Attribute style change
(defun c:asc ()
(setq atts(getstring "\nEnter new attribute style: "))
(command "attedit" "y" "*" "*" "*" "c" pause pause)
(while
(= 1 (logand (getvar "cmdactive") 1))
(command "s" atts "n")
);;; end while
);;; end lisp

;;;Attribute height change
(defun c:ahc ()
(setq atth(getreal "\nEnter new attribute height: "))
(command "attedit" "y" "*" "*" "*" "c" pause pause)
(while
(= 1 (logand (getvar "cmdactive") 1))
(command "h" atth "n")
);;; end while
);;; end lisp

;;;Attribute angle change
(defun c:aac ()
(setq atta(getint "\nEnter new attribute angle: "))
(command "attedit" "y" "*" "*" "*" "c" pause pause)
(while
(= 1 (logand (getvar "cmdactive") 1))
(command "a" atta "n")
);;; end while
);;; end lisp

;;;Attribute color change
(defun c:acc ()
(setq attc(getint "\nEnter new attribute color: "))
(command "attedit" "y" "*" "*" "*" "c" pause pause)
(while
(= 1 (logand (getvar "cmdactive") 1))
(command "c" attc "n")
);;; end while
);;; end lisp

;;;Attribute layer change
(defun c:alc ()
(setq attl(getstring "\nEnter new attribute layer: "))
(command "attedit" "y" "*" "*" "*" "c" pause pause)
(while
(= 1 (logand (getvar "cmdactive") 1))
(command "l" attl "n")
);;; end while
);;; end lisp

;;; Block attribute case change
(defun c:AttUpper ()
 (setq ATWC1(nentsel "\nSelect block data from: "))
  (setq ATWC2(car ATWC1))
   (setq ATWC3(entget ATWC2))
    (setq ATWC4(cdr(assoc 1 ATWC3)))
     (setq ATWC5(cdr(assoc 10 ATWC3)))
  (setq ATWCTXT (Strcase ATWC4))
(command "attedit" "n" "y" "*" "*" "*" ATWC5 "" ATWC4 ATWCTXT)
)

;;; Block attribute data transfer
(defun c:BADT ()
 (setq e1s(nentsel "\nSelect block data from: "))
 (setq e2s(nentsel "\nSelect block data to: "))
  (setq e1n(car e1s))
  (setq e2n(car e2s))
   (setq e1d(entget e1n))
   (setq e2d(entget e2n))
    (setq e1dd(cdr(assoc 1 e1d)))
    (setq e2dd(cdr(assoc 1 e2d)))
     (setq e1p(cdr(assoc 10 e1d)))
     (setq e2p(cdr(assoc 10 e2d)))
  (setq tt1 e1dd)
  (setq tt2 e2dd)
(command "attedit" "n" "y" "*" "*" "*" e2p "" tt2 tt1)
)

;;; Layer name to block attribute
(defun c:LTATT ()
 (setq en1s(nentsel "\nSelect entity on layer: "))
 (setq en2s(nentsel "\nSelect block data to: "))
  (setq en1n(car en1s))
  (setq en2n(car en2s))
   (setq en1d(entget en1n))
   (setq en2d(entget en2n))
    (setq en1dd(cdr(assoc 8 en1d)))
    (setq en2dd(cdr(assoc 1 en2d)))
     (setq en1p(cdr(assoc 10 en1d)))
     (setq en2p(cdr(assoc 10 en2d)))
  (setq ttn1 en1dd)
  (setq ttn2 en2dd)
(command "attedit" "n" "y" "*" "*" "*" en2p "" ttn2 ttn1)
)
Revit BDS 2017, 2016, 2015, 2014, AutoCAD 2017, 2016, Navisworks 2017, 2016, BIM360 Glue

CottageCGirl

  • Guest
Re: Editing Block Text Font???
« Reply #21 on: December 01, 2005, 08:30:38 AM »
Let me applaud your self control Mr. Murphy.

:lmao:

yes, but just by what Murphy said, it might as well have been said-- just like the bleeps on TV (BTW-not offended)

CottageCGirl

  • Guest
Re: Editing Block Text Font???
« Reply #22 on: December 01, 2005, 08:32:00 AM »
Hudster-I will try it later, I am on a deadline this AM :-D

MP

  • Seagull
  • Posts: 17750
  • Have thousands of dwgs to process? Contact me.
Re: Editing Block Text Font???
« Reply #23 on: December 01, 2005, 08:52:29 AM »
yes, but just by what Murphy said, it might as well have been said-- just like the bleeps on TV (BTW-not offended)

At least it's bleeped.

:)
Engineering Technologist • CAD Automation Practitioner
Automation ▸ Design ▸ Drafting ▸ Document Control ▸ Client
cadanalyst@gmail.comhttp://cadanalyst.slack.comhttp://linkedin.com/in/cadanalyst