CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products []
CZ | EN | DE
Login or
  Visitors: 12037

CAD tip CAD tip # 13911:

Question CAD 
 %  platform  category 
Q - question

How to print all sheets at once from Inventor?

A - answer With a simple iLogic rule, you can print a complete set of all sheets from your Inventor drawing, on a preset printer, by a single click of a button. It doesn't matter if you're printing to a physical printer, plotter, or PDF. In addition to the range of sheets, you can preset the scale, sheet format, number of copies, and other parameters.

Sub Main
    'Print all sheets in your Inventor drawing document
    If ThisApplication.ActiveDocument.DocumentType = kDrawingDocumentObject Then
        Dim oDrwgDoc As DrawingDocument
        oDrwgDoc = ThisApplication.ActiveDocument
        Dim oDrwgPrintMgr As DrawingPrintManager
        oDrwgPrintMgr = oDrwgDoc.PrintManager
        ' Set the printer name
        ' Printer name: comment this line to use the default printer or assign your own
        oDrwgPrintMgr.Printer = "Microsoft Print to PDF" ' "HP LaserJet 4000 Series PCL 6"
        'Set the paper size , scale and orientation
        oDrwgPrintMgr.ScaleMode = kPrintBestFitScale ' kPrintFullScale
        oDrwgPrintMgr.PaperSize = kPaperSizeA4
        oDrwgPrintMgr.PrintRange = kPrintAllSheets ' ALL SHEETS, or kPrintCurrentSheet or kPrintSheetRange
	'oDrwgPrintMgr.GetSheetRange(1,3) ' if Range
        oDrwgPrintMgr.Orientation = kLandscapeOrientation
	oDrwgPrintMgr.ColorMode = kPrintDefaultColorMode ' kPrintGrayScale
	oDrwgPrintMgr.NumberOfCopies = 1
	oDrwgPrintMgr.Rotate90Degrees = False
	oDrwgPrintMgr.AllColorsAsBlack = False
	oDrwgPrintMgr.RemoveLineWeights = False
	oDrwgPrintMgr.TilingEnabled = False
	MsgBox("Not a drawing!")
    End If
End Sub

You can assign a macro to a button in the ribbon for quick launching, e.g. using the functions of the bonus utility T4I.

100% *  CAD 
4.11.2023    1645×  
Prices - CAD eShop:
applies to: Inventor ·

See also:

Back   All CAD Tips

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   

Export 3D VRML scenes from AutoCAD and Inventor
VRMLout More info

Please use these tips at your own risk.
Arkance Systems is not responsible for possible problems that may occur as a result of using any of these tips.