CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz]
Cesky English Deutsch
Login/Register:
 Visitors: 4372 

CAD tip CAD tip # 11604:

Question CAD 
 %  platform  category 
Q - question

How to set plot transparency for all layouts in a DWG?

A - answer If you need to set the plot transparency option in the PLOT command for all layouts in your drawing, or even inclusive the Model, you can use the following simple LISP utility by CAD Studio.

Save the code to the AllLOT.LSP file (or download this LSP file from www.cadstudio.cz/download), load it into AutoCAD with APPLOAD and type the command AllLOT. You can change the code from "enable" to "disable" transparency in one go (1/0).


; Set Plot Transparency ON/off (CAD Studio, 2017 - www.cadstudio.cz  www.cadforum.cz)

(vl-load-com)

(defun c:AllLOT (/ aDoc Layouts itm)

(defun LayoutTransparency (layout OnOff / xType xData)
  (setq xData (vlax-make-safearray vlax-vbVariant '(0 . 1)))
  (setq xType (vlax-make-safearray vlax-vbInteger '(0 . 1)))
  (vlax-safearray-fill xData (list (vlax-make-variant "PLOTTRANSPARENCY")(vlax-make-variant OnOff)))
  (vlax-safearray-fill xType (list 1001 1071))
  (vla-setXdata layout xType xData)
  (entmod (entget (vlax-vla-object->ename layout) '("*")))
)

  (setq	aDoc (vla-get-activedocument (vlax-get-acad-object))
		Layouts (vla-get-layouts aDoc)
  )
  (foreach
	   itm
		  (layoutlist)
; or:
;		  (append '("Model") (layoutlist)) ; incl. Model
    (LayoutTransparency (vla-item Layouts itm) 1) ;       1=ON 0=off
  )
 (princ)
)

You can also temporarily override the plot/print transparency by setting the variable PLOTTRANSPARENCYOVERRIDE.

ACAD
100% *  CAD 
10.9.2017    424×  
Comments   Tell a friend
applies to: AutoCAD ·

See also:
Tip 9829:DrGrid - parametric grid for AutoCAD drawings.
Tip 8847:Xref objects are displayed in a different color.
Tip 8727:Transparent 3D views in Revit.
Tip 7570:Print XREF entities faded.


Back   All CAD Tips All CAD tips&tricks

Trim to rectangle - cut out a part of a DWG drawing. « | » Swept surface is not displayed in my Inventor model.

Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD:    OS:    Categ: 
Text:  FAQ glossary   



Featuring:
Use Google Earth images in your AutoCAD projects with the Plex.Earth Tools More info


Please use these tips at your own risk.
CAD Studio (Xanadu) is not responsible for possible problems that may occur as a result of using any of these tips.
TOPlist