How to print a empty page in a Layout

Hi experts,
i have a small requirement in forms. In my sapscript form i have 2 pages. its displaying properly the invoice layout.
But the new requirement is the user want to print a empty page as 1st page and remaining as per now current setting.
How to print a empty first page in a layout using sapscript?
Anyone help this issue?
Mohaha

Hi Mohana,
                Create one new page and one window of almost page size with no contents.  Move that window to this page.  Keep this page as first page and give earlier first page as next page to this newly created page.
                Hope this should solve the problem.
Regards
Sravan

Similar Messages

  • How to print envelopes in pages, How to print envelopes in pages

    How to print envelopes in pages, How to print envelopes in pages

    I presume you are using the Pages application, is that correct?
    So start off by launching Pages and choose one of the regular envelope styles. Traditional works well for me.
    Next go to the File menu and select Page setup. From the menu that says Paper Size select Manage Custom Sizes. In the resulting dialog, there should be a button on the left labeled "+". Click it. In the Paper Size area, select Width 5 in and Height 7 in. Name the size (where it says "untitled" something descriptive like "5 x 7 envelope". Click the OK button. The Paper Size menu here should now say the description you gave it. Click OK again. Your work area should now be a 5 x 7 envelope.
    Best of luck.
    PS If you are using Word or some other program, the process is probably the same or very similar.

  • Tutorial on how to print  multiple output pages

    Hi,
    I am rather sad that this forum does not provide a simple principle on how to printout multiple pages to newbie.
    Below is a short contribution from me on how to print across multiple pages, other reader are also encourage to modify the code to provide more robust tutorial .
    * How to use java to print across pages that are more than one
    * Short contribution to java forum by Eric gan (Malaysia)
    import java.awt.*;
    import java.awt.geom.*;
    import java.awt.print.*;
    import java.awt.Graphics2D;
    import java.awt.print.*;
    import java.awt.print.Book;
    import java.awt.print.Pageable;
    import java.awt.Graphics2D;
    import java.awt.Graphics;
    public class Example implements Printable {
    //--- Private instances declarations
    private int row_cnt=30; // set the total number of row per page
    private int cum_row_cnt=30; // set the counter to record total number of row per page to determine
    // whether maximum pages should be increase depending on the programme requirement
    private int max_pg=0; // set the maximum number of page
    public Example () {
    //--- Create a printerJob object
    PrinterJob printJob = PrinterJob.getPrinterJob ();
         printJob.setPrintable(Example.this);
    if (printJob.printDialog()) {
    try {
    printJob.print();
    } catch (Exception PrintException) {
    PrintException.printStackTrace();
    public void paint (Graphics g) {
    Graphics2D g2d;
    g2d = (Graphics2D) g;     
    int x=10;
    int y=10;
    for (int outline=0;outline<=160;outline+=20){
              if (y>cum_row_cnt){
              cum_row_cnt+=row_cnt;//counter should grow by value equal to row_cnt
         max_pg++;
         g2d.drawString("outline value ---> " +outline , x, y);
         y+=10; // to set the row printing interval      
    } // end of paint procedure
         public int print(Graphics g,
    PageFormat pf, int pi)
              throws PrinterException {
    // normal routine to check when should java stop the print looping
    if (pi >max_pg) {
    return Printable.NO_SUCH_PAGE;
    Graphics2D g2 = (Graphics2D) g;
         int fontHeight=g2.getFontMetrics().getHeight();
         int fontDesent=g2.getFontMetrics().getDescent();
         double pageHeight = pf.getImageableHeight()-fontHeight;
         double pageWidth = pf.getImageableWidth();
         // setting for the translate and graphics clipping to enable printing on output pages
    // row_cnt can be equal to pageHeight
    // in this examples assumming pageHeight=20 rows           
         g2.translate(pf.getImageableX(), pf.getImageableY());
    g2.translate(0f,-pi*row_cnt);
    g2.setClip(0, (int)(row_cnt* pi),
    (int) Math.ceil(pageWidth),
    (int) Math.ceil(row_cnt));
    paint(g2);
    return Printable.PAGE_EXISTS;
    public static void main (String [] args) {
    Example example = new Example ();
    System.exit (0);
    Thank

    Hello
    I know that Pages is using its own algorithm to resize pages when it put several of them on a single sheet.
    This is why I use this tip.
    I draw a rectangle whose size is supposed to be the final one.
    I give it a white background and a black border whose thickness is set to one point.
    For the tests I just insert three page breaks so that the document is a four pages one.
    I print it as is.
    Doing that, I may measure the printed rectangle.
    Of course, at first attempt it doesn't match the required size.
    It's easy to compute the required adjustments.
    When the correct factor is reached, it is easy to build the complete document so that it prints the correct size.
    Doing that I never got odd results but maybe it's because I am a lucky guy.
    Of course, disagreeing with one advice doesn't mean that I don't respect it.
    I respect your opinion, _on other matters too_
    Yvan KOENIG (from FRANCE mardi 6 mai 2008 17:24:09)

  • How to print 2 sided pages brochure

    how to print 2 sided pages brochure

    Hello kaskasnikola,
    I understand that you need to print 2 pages per page.
    1 Open the printer driver, and click the Finishing tab.
    2 Select the number of pages per sheet from the Pages
    per sheet drop-down list.
    3 Select the correct options for Print page borders,
    Page order, and Orientation.
    4 Click OK.
    If you are having any problems please post on our printer forums.
    Here is a link to the forum.

  • XDC - print a empty page after the print job

    Hi Folks,
    i have a problem. i use a xdc file to select multiple trays and after the printing job an additional separator sheet should be "printed" . Its only a empty sheet, which should be at the end of the printjob.
    Could somebody give me a hint? I checked the pcl commands and i got the idea to send a line feed and carriage return command, but im not sure whats happen and if this is possible, could i select the tray for this?
    Thanks a lot for any Idea or Tip,
    kind regards
    Alex

    Wasil, thanks for the response, but i havent found any info to do a separator sheet in this link. I know that i have to do this in the xdc, but i dont know how. I found a plc command to do this, but the problem is that i not understand how to fill this in the xdc.
    Here ist the Part from my XDC File. Ok, its possible that this is at the wrong point, but im sure i have an error in the escaping.
    The Printer i use is a Ricoh MP5002sp. I only found the escaping like i did, but i get a pdf generation error with this part:
       <seq id="postDoc"><ESC/>%-12345X@PJL RDYMSG DISPLAY=""&#13;&#10;<ESC/>H1B\L%-12345X@PJL ENTER LANGUAGE=PCL&#13;&#10;<ESC/>H1B\L&l4H&#13;&#10;<ESC/>H1B\L&l1T\0&#13;&#10;<ESC/>M\B\S\N\U &#13;&#10;<ESC/>U\LJob : \I&#13;&#10;<ESC/>U\LDate: \D&#13;&#10;<ESC/>U\LTime: \T&#13;&#10;<ESC/>E&#13;&#10;</seq>
    The PLC commands i foun on a website looks like this:
    \H1B\L%-12345X@PJL ENTER LANGUAGE=PCL    <-- Puts printer into PCL mode
    \H1B\L&l1H    <-- This command pulls the sep sheet from Tray 2
    \H1B\L&l1T\0    <-- Job Reset. Sets USTATUS counters etc,
    \M\B\S\N\U    <-- Prints user name in large characters
    \U\LJob : \I    <-- Prints spool ID number
    \U\LDate: \D   <-- Prints date
    \U\LTime: \T    <-- Prints time
    \E    <-- Exits banner page and begins actual print job
    But in my case it will be enough to select the tray and "print" the empty sheet...
    thanks a lot for your your help...and it could be a easy task...but it looks like im a "dau" :-)

  • Firefox does not correctly print - creates empty pages and cuts of content when printing

    When trying to print out pages Firefox first prints a lot of empty pages, and then only a part of the content. Example:
    https://online.medunigraz.at/mug_online/wbTvw_List.lehrveranstaltung?pStpSpNr=182778
    When entering "print prview" you can see empty pages.
    When printing this page with Internet Explorer all is fine.

    Thanks for this hint, but it does not help.
    This problem does not appear in Internet Explorer, and it should be reproduceable. At least I thought so, so it would help if others could try to click on the link and try to print. They should have the same troubles.
    https://online.medunigraz.at/mug_online/wbTvw_List.lehrveranstaltung?pStpSpNr=182778
    I also attach a Screenshot so that you can see how the Print Preview looks like.
    Kind regards,
    Herwig

  • How to print a specific page from the internet

    I have tried to print a specific page, and get about seven pages that are linked to it, without
    seeing the specific page I wanted printed out. The page settings under printer only lists header and footer
    info, and no choices to print only this page or frame. There is no way to print  one specific page on this printer?
    I always was able to do this  with the Epson printer I just replaced, but unable to with this printer.
    Please help! There must be a way to do this when printing from the internet. Thanks for any help.

    deezire
    Welcome to the HP Community Forum.
    I don't have any idea what you are trying to print, nor do I wish to know.  Smiling.
    The key may be to control this in Print Preview like you would with most things when you are printing from a Browser.
    Manage Print Output with Print Preview
    ========================================================================
    Depending on which browser you are using, you might also be able to make use of Smart Print:
    Downloads and Information:
    HP Printing Software
    Scroll down > look on the right side of the page under Web Page Printing for the HP Smart Print download
    How-To:
    Smart Print Help and FAQ
    Includes: How to update your installed version of Smart Print:
    #6: How do I get the latest version of Smart Print?
    Smart Print updates automatically using the default settings. You can choice to update manually by selecting the "?" on the Smart Print Preview/Print bar located in the upper left corner of Smart Print. Select the Updates tab to get the latest version.
    Click the Kudos Thumbs-Up to say Thank You!
    And...Click Accept as Solution when my Answer provides a Fix or Workaround!
    I am pleased to provide assistance on behalf of HP. I do not work for HP. 
    Kind Regards,
    Dragon-Fur

  • How to print chinese web page with netscape browserver in Solaris 9 OS ?

    Dear All,
    I would like to print chinese web page within netscape browser in Solaris 9 Traditional Chinese OS, the print out result is garbage code on the paper not correctly chinese fonts.
    I can print out correctly the chinese document create by StarSuite 7.0 on Solaris 9 OS environment and also the chinese web page is correctly display within Netscape browser but for printing is abnomal result.
    Can someone point me to how to do print chinese web page with browser in Solaris 9 environment ?
    Best Regards,
    -- Kuo

    hi
    i have encountered this problem before and i remember downloading some fonts package and installing it. u could google search your question and it should provide the solution.thats how i stumbled upon the package.
    cheers,
    bunny

  • How to get an empty page to fill content?

    every time we open a new template page, we get this pic, all was filled with words, how to get a n empty page or delete the words auto?

    Thank you all,
    but I intent to have a layout like that without words, so that I can put down the content.

  • How to print in java(page or whole frame with photos)

    Hell sir,
    My self kiran patel.I am going to devlop a visitor information system project for Ongc(stand-alon application)
    I want to know about below topics.
    (1) How to print simple page using printer in java.i dont know any code.
    (2) Printing page should contain the whole page which include information and photo of visitor.
    (3) how to catch the photo in data base or my frame of visitor info. which we have taken throw web-came.
    (4) can we store any image in database?
    Please help me as possible as soon.......
    kiran patel(MSc it)

    Background study -
    http://java.sun.com/docs/books/tutorial/2d/printing/index.html
    http://java.sun.com/docs/books/tutorial/jdbc/index.html

  • How to Print Without Cropping Pages

    I'm new to the Book tool, and cannot figure out how to print a book on my Epson 4800 printer without cropping the pages.
    I'm using Aperture 3.1.2 and OSX 10.6.6.
    I created a custom "Book Type" with a Page Size of 11 in. wide x 8.5 in. high.
    I created pages, added images, and tried to print. No matter what I do, I cannot get an 8.5 x 11" sheet to print with the same content as my 11 x 8.5" book pages.
    If it helps, I'm using cut sheet 8.5x11" paper in my Epson 4800.
    Thanks,
    Jim

    As Peter said, you can't with Pages, but you could export the file as a PDF & then print just the desired pages in Preview.

  • How to print booklet, 4 pages to an A3 ?

    I’d like to be able to print an 81-page  “A4 booklet” i.e. it is a set of A3 sheets, printed double sided with 2 A4 prints on each side of each A3 sheet so that there are 3 staples in the middle of the A3 sheet such that I can fold it into an “A4 booklet” and read it as such. I have an OKI 811 printer but there is no "booklet" setting. Can somebody please help?

    If the original file is PDF then Acrobat Pro can make booklets, although I don't know if you can make an A3 booklet from A4 originals. A quick test with Pro X shows that the booklet is made by shrinking the A4 to A5 and positioning the 2 x A5's on a rotated A4. But it does change the page order which is good to see.
    So you may have to look at software to make the A3 booklet. A quick search found Create Booklet for Mac and BookletCreator

  • How to print a specific page from a given PDF document, using command line, please?

    Hello,
    I need your advise, please. My customer requires to print a specfic page from a pdf document they receive, using command line or 3rd party solution.
    Anything you can advise, please? I have seen AcroRD32.exe options, but can only print the whole document.
    Kind Regards

    Not sure if there are any examples. The Acrobat SDK is a must, but it is best treated as documentation to study rather than examples to copy. The examples only illustrate a tiny fraction of the capabiliies.
    (One other note: the solution must involve the client owning Acrobat; Acrobat is not for server use).

  • Java printing problem how to print in multiple pages

    hi all
    i'm trying to print the output of my application
    no problems with the 1st page but i'd like to tell to my app to print in a brand new page if the content exceed the printable length of the first page. i have 2 classes: printer and Document. the last one implements Printable
    Printer code
    PrinterJob printJob = PrinterJob.getPrinterJob ();
          //--- Create a new book to add pages to
          Book book = new Book ();
          //--- Add the cover page using the default page format for this print job
          //book.append (new IntroPage (), printJob.defaultPage ());
          //--- Add the document page using a landscape page format
          PageFormat documentPageFormat = new PageFormat ();
          documentPageFormat.setOrientation (PageFormat.LANDSCAPE);
          //Document doc=new Document();
          //book.append (doc, documentPageFormat);  
          //book.append (new Getter(), documentPageFormat);  
          book.append (new Document(), documentPageFormat);  
          //--- Tell the printJob to use the book as the pageable object
          printJob.setPageable (book);
          System.out.println("AAAAAAAA" +book.getNumberOfPages());
          //--- Show the print dialog box. If the user click the
          //--- print button we then proceed to print else we cancel
          //--- the process.
          if (printJob.printDialog()) {
             try {
                printJob.print(); 
             } catch (Exception PrintException) {
                PrintException.printStackTrace();
          }Document code:
    public class Document implements Printable
        private final static int POINTS_PER_INCH = 72;
        Calendar now;
        DateFormat df;
        Date date;
        double width;
        Point2D.Double pen;
        Graphics2D g2d;
        LineBreakMeasurer lineBreaker;
        AttributedString paragraphText;
        TextLayout layout;
        double maxPen=0.0;
        static int x1,x2,x3,x4,x5,x6,x7,x8,x9,x10;
        static double intestY, textX, textY;
        public Document()
        public int print (Graphics g, PageFormat pageFormat, int page)
            pen = new Point2D.Double();
            //setto calendario e DateFormat per orario
            df=new SimpleDateFormat("HH:mm:ss:SSS");
            //now=GregorianCalendar.getInstance();       
            //date=now.getTime();
             //--- Create the Graphics2D object
             g2d = (Graphics2D) g;
             //--- Translate the origin to 0,0 for the top left corner
             g2d.translate(pageFormat.getImageableX (), pageFormat.getImageableY ());        
             g2d.setColor(new Color(204,204,204));
             Font titleFont = new Font ("arial", Font.PLAIN, 10);
             Font textFont = new Font ("arial", Font.PLAIN, 8);
             g2d.setFont (titleFont);
             //--- Compute the horizontal center of the page
             FontMetrics fontMetrics = g2d.getFontMetrics ();
             String text = "ABSOL s.r.l. - LISTA APPUNTAMENTI DI Marcello Baiguera";
             textX=(pageFormat.getImageableWidth() - fontMetrics.stringWidth(text))/2;
             textY =7.2;
             //g2d.drawString (text, (int) textX, (int) textY);
             g2d.setFont (textFont);
             fontMetrics = g2d.getFontMetrics ();        
             //linea orizzontale sotto il titolo
             textY=textY + fontMetrics.getDescent();
             //g2d.drawLine(0, (int)textY, (int)pageFormat.getImageableWidth(), (int)textY);
             //prima linea verticale - margine sx
             //g2d.drawLine(x1, (int)textY, x1, (int)pageFormat.getImageableHeight());
             //seconda linea vert 
             x2=x1+fontMetrics.stringWidth("ven. 31/12/2003 ");
             //g2d.drawLine(x2, (int)textY, x2, (int)pageFormat.getImageableHeight());
             //terza linea vert         
             x3=x2+fontMetrics.stringWidth("88:88 ");
             //g2d.drawLine(x3, (int)textY, x3, (int)pageFormat.getImageableHeight()); 
             //quarta linea vert         
             x4=x3+fontMetrics.stringWidth("Marcello Impegnato text text text text");
             //g2d.drawLine(x4, (int)textY, x4, (int)pageFormat.getImageableHeight());
             //quinta linea vert         
             x5=x4+fontMetrics.stringWidth("Sig D'alessio Gigione ");
             //g2d.drawLine(x5, (int)textY, x5, (int)pageFormat.getImageableHeight());   
             //sesta linea vert         
             x6=x5+fontMetrics.stringWidth("Via del PonteVico, 222222 ");
             //g2d.drawLine(x6, (int)textY, x6, (int)pageFormat.getImageableHeight());
             //settima linea vert         
             x7=x6+fontMetrics.stringWidth("del Bagnolo Del Mella (bs) ");
             //g2d.drawLine(x7, (int)textY, x7, (int)pageFormat.getImageableHeight());
             //ottava linea vert         
             x8=x7+fontMetrics.stringWidth("333/78547888 ");
             //g2d.drawLine(x8, (int)textY, x8, (int)pageFormat.getImageableHeight());       
             //nona linea vert         
             x9=x8+fontMetrics.stringWidth("Rinnovo Scadenza Il ");
             //g2d.drawLine(x9, (int)textY, x9, (int)pageFormat.getImageableHeight());
             //decima linea vert         
             x10=x9+fontMetrics.stringWidth("Sandropolitan")+2;
             //g2d.drawLine(x10, (int)textY, x10, (int)pageFormat.getImageableHeight());
             intestY=textY+12;
             text = "DATA";
             textX= x1+((x2-x1)-fontMetrics.stringWidth(text))/2;                 
             //g2d.drawString (text, (int) textX, (int) intestY); 
             text = "ORA";
             textX= x2+((x3-x2)-fontMetrics.stringWidth(text))/2;                 
             //g2d.drawString (text, (int) textX, (int) intestY); 
             text = "CLIENTE";
             textX= x3+((x4-x3)-fontMetrics.stringWidth(text))/2;
             //g2d.drawString (text, (int) textX, (int) intestY); 
             text = "REFERENTE";
             textX= x4+((x5-x4)-fontMetrics.stringWidth(text))/2;
             //g2d.drawString (text, (int) textX, (int) intestY); 
             text = "INDIRIZZO";
             textX= x5+((x6-x5)-fontMetrics.stringWidth(text))/2;
             //g2d.drawString (text, (int) textX, (int) intestY); 
             text = "CITTA'";
             textX= x6+((x7-x6)-fontMetrics.stringWidth(text))/2;
             //g2d.drawString (text, (int) textX, (int) intestY);        
             text = "TELEFONO";
             textX= x7+((x8-x7)-fontMetrics.stringWidth(text))/2;
             //g2d.drawString (text, (int) textX, (int) intestY); 
             text = "MOTIVAZIONE";
             textX= x8+((x9-x8)-fontMetrics.stringWidth(text))/2;       
             //g2d.drawString (text, (int) textX, (int) intestY); 
             text = "APP. CON";
             textX= x9+((x10-x9)-fontMetrics.stringWidth(text))/2;
             //g2d.drawString (text, (int) textX, (int) intestY);       
             textY=intestY+6;
             //g2d.drawLine(0, (int)textY, (int)pageFormat.getImageableWidth(), (int)textY);
             textY=textY+12;
             double initialTextY=textY;
             System.out.println("maximum Y: "+pageFormat.getImageableY());
             Vector maxPens=new Vector();
             boolean vai=true;
             for(int i=0;  i<12; i++ )
                 if(textY<400.00 && vai)
                     System.out.println("");
                     System.out.println("-- "+i+" --"+df.format(new Date()));
                     //data
                     text = Integer.toString(i);
                     //textX= x1+((x2-x1)-fontMetrics.stringWidth(text))/2;
                     pen.x=x1+2;                
                     printJustified(text, x2-x1-4,textY);
                     //ora
                     text = "10:00";
                     //textX= x2+((x3-x2)-fontMetrics.stringWidth(text))/2;          
                     pen.x=x2+2;                
                     //printJustified(text, x3-x2,textY);
                     //cliente
                     text = "Costruzioni Benedini";        
                     pen.x=x3+2;
                     //printJustified(text, x4-x3-4,textY);
                     //referente
                     text = "Sig. Alessandro mmmm mmmm mmm mmmm mm  ";
                     pen.x=x4+2;
                     //printJustified(text, x5-x4-4, textY);
                     //indirizzo
                     text = "Via del Ca'";
                     pen.x=x5+2;
                     //printJustified(text, x6-x5-4,textY);
                     //citta' + (prov)
                     text = "Pozzolengo S. (VR)";
                     pen.x=x6+2;
                     //printJustified(text, x7-x6-4,textY);
                     //telefono
                     text = "335/6998523";
                     pen.x=x7+2;
                     //printJustified(text, x8-x7-4,textY);
                     //motivazione
                     //text = "Primo Appun";
                     pen.x=x8+2;
                     //printJustified(text, x9-x8-4,textY);
                     //Appuntamento con
                     //text = "Alessandro";
                     pen.x=x9+2;
                     //printJustified(text, x10-x9-4,textY);        
                     //textY=pen.y+12;
                     try
                        textY=Double.valueOf(maxPens.get(i).toString()).doubleValue()+12;
                        System.out.println(i+" recuperato");
                     catch(ArrayIndexOutOfBoundsException a)
                         maxPens.add(Double.toString(maxPen));
                         textY=maxPen+12;
                         System.out.println(i+" aggiunto");
                 else
                     System.out.println("aaaaaaaaaaaaaa ("+textY+")");
                     vai=false;
             //--- Validate the page
             return (PAGE_EXISTS);
             //return(NO_SUCH_PAGE);
          void printJustified(String text, double width, double y)
             pen.y=y;
             String txt=text;   
             System.out.println("text: "+text+" - pen.y= "+y);
             paragraphText = new AttributedString (txt);
             paragraphText.addAttribute (TextAttribute.FONT, new Font ("arial", Font.PLAIN, 8));
            //--- Create a LineBreakMeasurer to wrap the text for the TextLayout object
            //--- Note the second parameter, the FontRendereContext. I have set the second
            //--- parameter antiAlised to true and the third parameter useFractionalMetrics
            //--- to true to get the best possible output
            lineBreaker = new LineBreakMeasurer (paragraphText.getIterator(), new FontRenderContext (null, true, true));
             //--- Create a Vector to temporaly store each line of text
             Vector lines = new Vector ();
             //--- Get the output of the LineBreakMeasurer and store it in a Vector
             while ((layout = lineBreaker.nextLayout ((float) width)) != null) {
                lines.add (layout);
             pen.y = pen.y - 7.373047;
             //--- Scan each line of the paragraph and justify it except for the last line
             for (int i = 0; i < lines.size (); i++)
                //--- Get the line from the vector
                layout = (TextLayout) lines.get (i);
                //--- Check for the last line. When found print it
                //--- with justification off
                //--- Align the Y pen to the ascend of the font, remember that
                //--- the ascend is origin (0, 0) of a font. Refer to figure 1
                pen.y += layout.getAscent ();
                //--- Draw the line of text
                layout.draw (g2d, (float) pen.x, (float) pen.y);
                //--- Move the pen to the next position adding the descent and
                //--- the leading of the font
                pen.y += layout.getDescent () + layout.getLeading ();
                if (pen.y>maxPen)
                    maxPen=pen.y;
                    System.out.println("-----------------------------------------------txt: "+txt+" new maxPeny= "+maxPen);
       }in Document i use the printJustified method that simply splits the text in rows.
    i'll don't explain the method 'cause my question is another.
    thanx a lot
    please!!!
    sandro

    Basically you need to write some smart code. Your application needs to be able to determine what to print on each page because the print api will call the following function passing a page number. Your application must know what to paint on each page. If you think it sounds complicated you better believe it is !!
    public int print(Graphics g, PageFormat pf, int pageIndex) {
    PageNumber = pageIndex+1;
    // Need to calc the pages here
    page = (Graphics2D)g;
    calcPages();
    say("Printing page " + PageNumber);
    if (PageNumber <= getNumPages()) {
    paint(g);
    return Printable.PAGE_EXISTS;
    } else
    return Printable.NO_SUCH_PAGE;
    The code above comes from my report printer class and as you can see a calcPages() function is called prior to the paint() function being called. This function sets up a whole bunch of things including exactly what needs to be printed on each page. Note that the calcPages() function is smart enought to simply return is it has already been called. This way the paint function simply checks the PageNumber variable when painting to establish what to draw on the page.
    So imagine when you are generating a very large report from a database ! You basically have to process the report doing all the formatting prior to actually allowing the paint function to be called. Its quite a complicated business but fortunately even the largest report does'nt really take up that much memory. I basically just create buffers of the data for each page - its a bit of a pain but the same logic is required for pagination anyway.
    Be happy to provide you with the source code but you might need the whole application to get anything working.

  • How to print comments in Pages 5.0

    Is it still impossible to print comments in pages?

    When you installed Pages v5, it automatically moved the older Pages ’09 v4.3 into /Applications/iWork '09 folder. If you want normal comment interoperability, you are advised to resume using the older version of Pages. Newer, is certainly not better with Pages v5.

Maybe you are looking for