stephen.coff
2007-04-20, 04:55 AM
Guys,
I have made a very simple routine that saves the current view to a number supplied by the user between 1 - 5. I further created lisp routines, 5 of them. I for each possible view saved so i can save them as icons in a toolbar so I just press the number icon I want to recall that saved view. I have tried it and it actually works ok except one thing. If you save a view in one tilemode and then move to another and save a view. It becomes a problem when you try to recall the views, it won't flick between the tilemodes
I wanted to be able to save what tilemode the drawing was in with the saved view. I was thinking that I could save the tilemode view with a variable ?. I just don't know how to do it, I tried multiple things though not successful. Maybe their is a very easy way and open to any suggestions.
This routine was to save the Views
(defun c:VS (/ VAL)
(setvar "cmdecho" 0)
(setq VAL (getint "Number to Save View: 1-5"))
(if (= (command "_view" "s" VAL) nil) (alert "View Saved"))
(setvar "cmdecho" 1)
(princ)
)This routine was one of 5 to restore the individual view
(defun c:V1 ()
(setvar "cmdecho" 0)
(command "_view" "r" "1")
(setvar "cmdecho" 1)
(princ)
)Any suggestions guys ?
Stephen
[ Moderator Action = ON ] What are [ CODE ] tags... (http://forums.augi.com/misc.php?do=bbcode#code) [ Moderator Action = OFF ]
I have made a very simple routine that saves the current view to a number supplied by the user between 1 - 5. I further created lisp routines, 5 of them. I for each possible view saved so i can save them as icons in a toolbar so I just press the number icon I want to recall that saved view. I have tried it and it actually works ok except one thing. If you save a view in one tilemode and then move to another and save a view. It becomes a problem when you try to recall the views, it won't flick between the tilemodes
I wanted to be able to save what tilemode the drawing was in with the saved view. I was thinking that I could save the tilemode view with a variable ?. I just don't know how to do it, I tried multiple things though not successful. Maybe their is a very easy way and open to any suggestions.
This routine was to save the Views
(defun c:VS (/ VAL)
(setvar "cmdecho" 0)
(setq VAL (getint "Number to Save View: 1-5"))
(if (= (command "_view" "s" VAL) nil) (alert "View Saved"))
(setvar "cmdecho" 1)
(princ)
)This routine was one of 5 to restore the individual view
(defun c:V1 ()
(setvar "cmdecho" 0)
(command "_view" "r" "1")
(setvar "cmdecho" 1)
(princ)
)Any suggestions guys ?
Stephen
[ Moderator Action = ON ] What are [ CODE ] tags... (http://forums.augi.com/misc.php?do=bbcode#code) [ Moderator Action = OFF ]