Jump to content

Recommended Posts

Posted

I'm looking to create a script which will change the pagesetup of my layouts in a file. some of my old templates/ file use dont all have the same pagesetup and can be quite lengthy to change them all manually

is there a easier way to go through all tabs/ layouts in a file and change them all to (portrait & landscape will vary but should already be set ) im strugglign to find any thing which i can use as a reference to change them in a script

image.thumb.png.ef8aa10248cf1d2b5276a67e4d0158a5.png

Posted

My way around it was ignore pagesetup and use a lisp to plot, from a menu pick output device and it all just happens. The latest version checks title blocks so can have a mix of Landscape or portrait and sheet size. It does though require company std title blocks not random plotting.

 

One version pick say plot A3 would send to printer on correct floor of multistorey building, that was based on user name known location, so they did not select a printer, our company 1000 pc's.

Posted

Without the use of Lisp, you can set the Pagesetup for multiple files using DWG Convert.

 

Posted

Someone here wrote this for me some time ago...

It takes the current page setup and copies it to all layouts.

I usually setup my first layout the way I want, give it a name then run the routine...

 

;; Copy current layout page setup to all layout tabs
(vl-load-com)
(defun c:test (/ Adoc Layts clyt)
(prompt "\nCopy current layout page setup to all layout tabs.")
  (setq	aDoc  (vla-get-activedocument (vlax-get-acad-object))
	Layts (vla-get-layouts aDoc)
	clyt  (vla-get-activelayout aDoc)
  )
  (foreach
	    itm
	       (vl-remove (vla-get-name clyt) (layoutlist))
    (vla-copyfrom (vla-item Layts itm) clyt)
  )
  (princ)
)

 

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...