Hello everyone, I have a file with several points and I would like to increase the scale of all.
I attached a Dwg because the LSP does not work?
(defun c:DEMO1() (setq ss (ssget '((0 . "INSERT")(2 . "PONTO COTADO"))) ct 0 sc (getreal "\nScale: ")) (repeat (sslength ss) (setq inspt (cdr (assoc 10 (entget (ssname ss ct))))) (command "_.Scale" ss "" inspt sc) (setq ct (1+ ct)) ) (princ) )
Solved! Go to Solution.
Solved by Kent1Cooper. Go to Solution.
It's true that each SCALE command should be doing the one Block under consideration at the time, not the entire selection set. But the worse problem is that the insertion point of that Block is 7417222.3813 drawing units (!) away from the center of the Circle in it, and that's the location they're being scaled around, which of course sends them off to outer space. You need to redefine the Block so its insertion point is at the center of that Circle [and MOVE all of them accordingly].
You can try a routine to redefine the insertion point of a Block such as >>this<< which claims [I haven't tried it] to keep all insertions where they are, compensating for different scales and rotations. There are others out there -- that's just one I know where to find.
If that doesn't work, here's what I'd do, since they're all at the same scale and at a rotation angle of 0:
Draw a temporary LINE from [Osnap INS to] the INSertion point of one of the Blocks to the CENter of its Circle element. [In the INSert Osnapping, hover your Aperture box over the Circle element, away from any of the Attributes, so it will go to the overall Block's insertion point.] Call up REFEDIT and pick that Block. MOVE all the pieces in it from that end of the temporary Line to the other end of it, that is, from the center of the Circle to the actual insertion point of the Block. Save the changes. Then go to the other end of that extremely long Line, and MOVE all those Blocks from that end to the end that's in the area of your other drawn objects. ERASE the Line.
And in the future, never accept the default 0,0,0 in the dialog box for the insertion point when defining a Block! Always specify a logical insertion point in relation to the drawn elements.
Can't find what you're looking for? Ask the community or share your knowledge.