CADTutor: The best free help for AutoCAD on the web

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
Go Back   AutoCAD Forums > AutoCAD > AutoCAD Beginners' Area

Reply
 
Thread Tools
Old 19th May 2008, 07:32 am   #1
psyfr3ak
Full Member
 
psyfr3ak's Avatar
 
Using: AutoCAD 2007
 
Join Date: Mar 2007
Location: Bucharest, Romania
Posts: 47
Default how can I scale an object only on one dimension?

hello
i have a picture with a diagram, and i want to scale it diferently on X and Y axe. maybe with extend? if this is the command please explain me how.
thanks
psyfr3ak is offline   Reply With Quote
Old 19th May 2008, 08:08 am   #2
Shiloh
Full Member
 
Using: AutoCAD 2009
 
Join Date: Dec 2006
Location: Barcelona, Catalunya
Posts: 87
Default maybe

or you could insert it as a block and deform the x-y coordinates at insertion
Shiloh is offline   Reply With Quote
Old 19th May 2008, 11:28 am   #3
Hoozin
Senior Member
 
Hoozin's Avatar
 
Using: Inventor 2009
 
Computer Details
 
Join Date: Feb 2008
Location: Northern Virgina, USA
Posts: 165
Default

If you know what scales it needs and you're talking about putting in a raster image, you can choose 1-Dimensional scales on the insertion prompt.

If it's something else, block it and change the X and Y Scales in the properties window.
Hoozin is offline   Reply With Quote
Old 19th May 2008, 12:07 pm   #4
Tiger
Super Moderator
 
Tiger's Avatar
 
Using: AutoCAD 2010
 
Computer Details
 
Join Date: Nov 2006
Location: Wintery Sweden
Posts: 2,838
Default

Noticed that the scaleaxis.lisp has been remove, so here it is a agian - no idea who the author is and it changes everything to lines but it is a simple way to scale everything in one direction.

Code:
;;;SCALEAXIS.LSP

;--------------------------------------------------
; ERROR TRAPPING
;--------------------------------------------------

(defun errtrap (msg)
  (cond
    ((not msg))
    (
      (member msg '("Function cancelled" "quit / exit abort"))
      (command "undo" "")
    )
    (
      (princ (strcat "\nError: " msg))
      (command "undo" "")
    )
  );cond
);defun

;--------------------------------------------------
;  MAIN ROUTINE
;--------------------------------------------------

(defun c:scaleaxis (/ *error* *ss1 bspt ax mult refpt refdx newdx)

(command "._undo" "end" "._undo" "begin")
(setq *error* errtrap)

(setq ss1 (ssget))
(setq bspt (getpoint "\nSelect basepoint: "))
(initget "X Y Z")
(if
  (not
    (setq ax (getkword "\nSpecify axis to scale: <X> "))
  );not
  (setq ax "X")
);if

(if
  (not 
    (setq mult (getreal "\nEnter scale factor or <Reference>: "))
  );not
  (progn
    (setq refpt1 (getpoint "\nSpecify reference length: "))
    (setq refdx (getdist refpt1 "\nSpecify second point: "))
    (setq newdx (getdist refpt1 "\nSpecify new length: "))
    (setq mult (/ newdx refdx))
  );progn
);if

(setvar "expert" 2)
(setvar "explmode" 1)
(command "._-block" "SCALETEMP" bspt ss1 "")
(command "._-insert" "SCALETEMP" ax mult bspt "0")
(command "._explode" "last" "")
(command "._-purge" "blocks" "SCALETEMP" "n")
(setvar "expert" 1)

(command "._undo" "end")

(princ)
(*error* nil)
)

I blame the fish!
Tiger is offline   Reply With Quote
Old 19th May 2008, 12:11 pm   #5
LCE
Super Member
 
Using: Architecture 2009
 
Join Date: Apr 2008
Location: London, (sunny UK)
Posts: 686
Default

As others have said, block it, set axis scale and then explode it if you need.
LCE is offline   Reply With Quote
Old 30th May 2009, 01:00 pm   #6
stianhaugli
Forum Newbie
 
Using: AutoCAD 2010
 
Join Date: May 2009
Posts: 1
Default Fit.lsp

Hi, This is my first post in your forum :-)
I see this is becoming a rather old thread, but i'd like to mention a Lisp we've called "fit.lsp". it works with autocad 2000 - 2010, and it quite neately solves the problem.

We wrote this little piece long ago, and I thought I'd share it
You can download it from our site. (i just got blocked by your forum saying only users with 9 posts or more can post weblinks, so here it is - in Morse Code) 3xw dot xordesign dot com and click the Toolbox.

maybe someone (with the magic 9) could re post a proper link?

I havent "kelvinated" the lisps as i dont mind you guys reading the code and are sharing under one condition: Do Not remove the credentials (please?)

Pleaes dont look at the rest of the site. we dont have much time to update it ..
best
STIAN
stianhaugli is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Scale object by same dimension all round jordie1944 AutoCAD Beginners' Area 2 26th Mar 2008 11:32 pm
Dimension scale problem DanS1982 AutoCAD 2D Drafting, Object Properties & the Interface 25 3rd Mar 2008 03:23 pm
How to scale using a known dimension nscherneck AutoCAD Drawing Management & Output 2 21st Aug 2007 05:01 pm
dimension scale problem dreamer AutoCAD Drawing Management & Output 3 27th Jun 2005 04:59 pm
keep the same distance of dimension line to object JosMulder AutoCAD Beginners' Area 5 29th Jan 2005 03:10 pm

Why Donate?


All times are GMT +1. The time now is 11:51 am.

RSS Feed for AutoCAD ForumsValid XHTML 1.0!Valid CSS!Creative Commons Licence