Publisher (的 PrintableRect 物件)

代表指定印表機將在其中列印的紙張區域。 可列印矩形由印表機根據指定的紙張大小來決定。 印表機紙張的可列印矩形不應與出版物頁面的邊界區域相混淆;它可能大於或小於出版物頁面。

註解

在印表機紙張和出版物頁面大小相同的情況下,出版物頁面將置於印表機紙張的正中,且即使選取了印表機的任何標記,它們也不會列印出來。

使用 Printer.PrintableRect 屬性可傳回 PrintableRect 物件。

範例

下列範例會傳回使用中出版物的印表機工作表的可列印的矩形界限。

Sub ListPrintableRectBoundaries() 
 
With ActiveDocument.AdvancedPrintOptions.PrintableRect 
 
 Debug.Print "Printable area is " & _ 
 PointsToInches(.Width) & _ 
 " by " & PointsToInches(.Height) & " inches." 
 Debug.Print "Left Boundary: " & PointsToInches(.Left) & _ 
 " inches (from left)." 
 Debug.Print "Right Boundary: " & PointsToInches(.Left + .Width) & _ 
 " inches (from left)." 
 Debug.Print "Top Boundary: " & PointsToInches(.Top) & _ 
 " inches(from top)." 
 Debug.Print "Bottom Boundary: " & PointsToInches(.Top + .Height) & _ 
 " inches(from top)." 
 
End With 
 
End Sub 

屬性

另請參閱

支援和意見反應

有關於 Office VBA 或這份文件的問題或意見反應嗎? 如需取得支援服務並提供意見反應的相關指導,請參閱 Office VBA 支援與意見反應