Author Topic: Scale Objects  (Read 3604 times)

0 Members and 1 Guest are viewing this topic.

Fabricio28

  • Swamp Rat
  • Posts: 666
Scale Objects
« on: July 01, 2022, 02:43:58 PM »
Hi friends

I have two blocks and I'd like to make B just like A.

Is there any autocad command to do that? Maybe scale by reference points.

Example file attached.

Thanks

danAllen

  • Newt
  • Posts: 132
Re: Scale Objects
« Reply #1 on: July 01, 2022, 04:43:23 PM »
Align command with scale option?

Fabricio28

  • Swamp Rat
  • Posts: 666
Re: Scale Objects
« Reply #2 on: July 04, 2022, 11:12:53 AM »
Align command with scale option?
Dan
Awesome!! Thanks

Fabricio

Biscuits

  • Swamp Rat
  • Posts: 502
Re: Scale Objects
« Reply #3 on: August 19, 2022, 08:06:36 AM »
Found this one years ago and I have no idea who the credit goes to.


Code: [Select]
; Match scale of one block to another

(defun c:mbl ()
(setq fb (entget (car (entsel "\nSelect Block reference: ")))
fb41 (assoc 41 fb)
fb42 (assoc 42 fb)
)
(setq sb (entget (car (entsel "\nSelect target Block: ")))
sb41 (assoc 41 sb)
sb42 (assoc 42 sb)
)
(setq sb_ent (subst fb41 sb41 sb))
(entmod sb_ent)
(setq sb sb_ent)
(setq sb_ent (subst fb42 sb42 sb))
(entmod sb_ent)
(command "regen")
)

Crank

  • Water Moccasin
  • Posts: 1503
Re: Scale Objects
« Reply #4 on: August 20, 2022, 02:16:30 AM »
@ Biscuits:
Regen has some impact on big drawings. You better replace (command "regen") with
Code: [Select]
(entupd sb_ent)
(princ)
And you should localize your variables.
Vault Professional 2023     +     AEC Collection