leonucadomi Posted April 11 Posted April 11 hello: How can I change the layout configuration from lsp? change JPG to IMPRIMIR EN A3, without opening the pagesetup window I need to change that in many files. Is there a variable that changes it from lsp? Quote
BIGAL Posted April 12 Posted April 12 Are you plotting single dwg then use a plot lisp that has correct output printer hard coded. Quote
pkenewell Posted April 12 Posted April 12 (edited) @leonucadomi Maybe This? Not able to test it without a drawing. Use command SETCURPSETUP to change the Page Setup of the current layout. You can also remove the (if (= lay (getvar "ctab")) and the end parenthesis, leaving just (putpagesetup lay "IMPRIMIR EN A3") to apply to all layouts. ; Jason Piercey . May 16th, 2003 ; assign a pagesetup to a layout ; [layout] - string, layout name ; [setup] - string, pagesetup to assign ; return: T or nil (defun putPagesetup (layout setup / layouts plots) (defun item-p (collection item) (if (not (vl-catch-all-error-p (vl-catch-all-apply '(lambda () (setq item (vla-item collection item))) ) ) ) item ) ) (and (or *acad* (setq *acad* (vlax-get-acad-object))) (or *doc* (setq *doc* (vla-get-activedocument *acad*))) (setq layouts (vla-get-layouts *doc*)) (setq plots (vla-get-plotconfigurations *doc*)) (setq layout (item-p layouts layout)) (setq setup (item-p plots setup)) (not (vla-copyfrom layout setup)) ) ) (defun c:SetCurPsetup (/ lay) (foreach lay (layoutlist) (if (= lay (getvar "ctab"))(putPagesetup lay "IMPRIMIR EN A3")) ) (princ) ) There is also this: http://www.theswamp.org/index.php?topic=38005.msg430212#msg430212 Edited April 12 by pkenewell 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.