Visual LISP, AutoLISP and General Customization
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Why dose magnification work for Iso but not the back front top bottom ect?

1 REPLY 1
Reply
Message 1 of 2
The_Caddie
237 Views, 1 Reply

Why dose magnification work for Iso but not the back front top bottom ect?

Hi,

 

We use the following lisps in place of the AutoCAD isometric view buttons because they don’t loose their modification:

 

(defun C:MyNE ( )

   (setq MyCtr (getvar "viewctr"))

(setq MyMag (getvar "viewsize"))

   (Command "View" "neiso")

   (Command "Zoom" "C" Myctr MyMag)

)

 

 

The buttons work perfectly for the Isometric NE, NW, SE, and SW

Obviously we then wanted to apply the same principal to its cousins; the back, front left right top and bottom however the magnification doesn’t seem to want to hold for some reason.

 

I have analysed the code over and over and all we are doing is setting the view centre and magnification so it has now become beyond my understanding to why the following lisps (back taken as example) for these don’t work the same way.

 

Could anyone elaborate?

 

(defun C:MyBack ( )

   (setq MyCtr (getvar "viewctr"))

(setq MyMag (getvar "viewsize"))

   (Command "View" "Back")

   (Command "Zoom" "C" Myctr MyMag)

)

 

 

The_Caddie

1 REPLY 1
Message 2 of 2
Kent1Cooper
in reply to: The_Caddie

I'm not sure why that would be happening, though it might be that if you changed the UCS at the same time, the magnification would "hold" for you.  But the problem of the Zoom-Extents character of VIEW [and consequently of AutoCAD's Views Toolbar] came up here before, and I arrived at a different approach.  Try this out:

http://cadtips.cadalyst.com/other/3d-view-assistant

It uses the DVIEW command rather than VIEW and ZOOM, thereby preserving magnification, and changing only the direction of view.  It also covers many more directions of view [e,g, all isometric angles from below] than AutoCAD's Views Toolbar [you can substitute/add them into that if you like].  And it does not require having any named Views.

Kent Cooper, AIA

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost