With Me.Printer
        .PaperSize = 255
        .PaperHeight = 6860     '12.1cm
        .PaperWidth = 10828     '19.1cm
        .Orientation = ddOPortrait
    End With

解决方案 »

  1.   

    试试:
    ar.printer.DeviceName = ""
    ar.printer.papersize=256
    ar.printer.paperheight=1440*3
    ar.pritner.paperwidth=1440*8  KnowledgeBase Article: 1221
    Why does setting a custom papersize not work? 
    There are a couple of reasons why setting a custom paper size might not work. 
        1. The project is setting the paper size at an inappropriate time. In order for the paper size to be changed, it must be done in or before the ActiveReports_ReportStart sub. 
        2. The paper size is not supported by the printer since not all printers support every type of papersize. This can easily be tested by setting the .Printer.DeviceName = "" before changing the paper size. If, after nulling out the DeviceName, the custom paper size works, chances are the printer does not support the particular size being specified. 
    ActiveReport's printer object has a .PaperSizes property. This can be uses to cycle though all available paper sizes for the default printer. Below is a sample code for how to use this property.    Dim I As Long 
        For I = 0 To ActiveReport1.Printer.PaperSizes.Count - 1 
            ActiveReport1.Printer.PaperSize = ActiveReport1.Printer.PaperSizes(I) 
            Debug.Print ActiveReport1.Printer.PaperSizes(I) & " - " & _ 
              ActiveReport1.Printer.PaperWidth & " twips X " & _ 
              ActiveReport1.Printer.PaperHeight & " twips " 
        Next I