Lisp for setting "plot paperspace last" option

Lisp for setting "plot paperspace last" option

rosader
Enthusiast Enthusiast
1,114 Views
4 Replies
Message 1 of 5

Lisp for setting "plot paperspace last" option

rosader
Enthusiast
Enthusiast

I feel like I'm elementary level when it comes to my lisp knowledge so forgive me if this is a noob question.

I have a series of different page setup lisps that set the paper size, plot scale, etc. for all tabs in the project but there's an issue I've run into. I have schedules in paperspace that contain a mask but viewport objects print in front of the paperspace objects unless I set "plot paperspace last" under plot options. I can't seem to figure out how to change that setting using lisp. How would I modify the following lisp to check that option?

(defun c:2436a (/ lname s#)
(setvar "cmdecho" 0)
(setvar "ctab" (nth 0 (layoutlist)))
(setq lname (getvar "ctab")
s# 0
);setq
(repeat (length (layoutlist))
(setq lname (nth s# (layoutlist))
);setq
(command "-plot" "y" lname "KIP 7100 Series" "24x36in." "i" "l" "n" "e" "1=1" "c" "y" "1 IRIDIUM (2016).ctb" "y" "y" "y" "n" "n" "y" "n")
(setq s# (+ 1 s#))
(setvar "ctab" (nth s# (layoutlist)))
);repeat
(setvar "ctab" (nth 0 (layoutlist)))
(princ) (princ "All Done") (princ)
);defun c:

0 Likes
Accepted solutions (1)
1,115 Views
4 Replies
Replies (4)
Message 2 of 5

paullimapa
Mentor
Mentor
Accepted solution

when you follow the plot sequence by entering at the command prompt: -PLOT

you'll see that after the ctb the 3rd Y needs to be changed to N:

paullimapa_0-1685993493274.png

 


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 3 of 5

rosader
Enthusiast
Enthusiast

Thank You! This lisp was written by someone else who no longer works here and I guess I was looking for the hard way to fix it when it was just something super simple. Thank You

0 Likes
Message 4 of 5

paullimapa
Mentor
Mentor

you are welcome...cheers!!!


Paul Li
IT Specialist
@The Office
Apps & Publications | Video Demos
0 Likes
Message 5 of 5

Sea-Haven
Mentor
Mentor

A couple of freebies. Plots a range of layouts. Change the plot code to match yours above. 

SeaHaven_0-1686015242275.png

 

 

0 Likes