TheSwamp

Code Red => AutoLISP (Vanilla / Visual) => Topic started by: jsr on February 01, 2012, 06:43:23 AM

Title: viewport properties
Post by: jsr on February 01, 2012, 06:43:23 AM
Hi all,

These days I am working on drawings (from 3rd party) having 20 to 30 title print layouts in each drawing. The layer properties (on/off/freeze) are not set and I have to change them for every viewport before printing. I am doing it manually, which is time taking and error prone. Is their some easy way to set these properties of all viewports in one go. I am using AutoCAD 2010.

Thanks.
Title: Re: viewport properties
Post by: alanjt on February 01, 2012, 08:31:56 AM
Have you looked at the VPLayer command?
Title: Re: viewport properties
Post by: irneb on February 01, 2012, 08:39:24 AM
Exactly: the VPLayer (http://docs.autodesk.com/ACD/2011/ENU/filesACR/WS1a9193826455f5ffa23ce210c4a30acaf-5243.htm) command. Sorry, don't know if it's available in 2010 with overrides as well, in 2008 it only has the freeze/thaw per layer, in 2011 you can change colour, linetype, etc. Notice it asks you to which VP's you need to apply each change - one of the options is ALL.

You need to ensure you're on a PS tab (i.e. TILEMODE=0 ). Then perform the changes through VPLayer's command-line options. This you could easily save into a SCR file (a normal text file containing all the keystrokes you'd have typed in the AutoCAD command line). Then you can run this SCR on multiple DWGs by sending it through ScriptPro/AutoScript/other.

Otherwise some lisp and layer states might also solve your issue.
Title: Re: viewport properties
Post by: Patrick_35 on February 02, 2012, 09:09:17 AM
Hi

Are you trying GEF (http://patrick.blog-cao.com/2010/10/13/gef-v3/) ?
(it's working in english)

@+
Title: Re: viewport properties
Post by: jsr on February 05, 2012, 11:01:23 PM
Thanks everybody for giving valuable suggestions.