Page number wise printing of sapscript

Dear All,
I have SAPSCRIPT program for SAP FI/CO voucher printing .
The problem is that the user has to select each and every page to print after they have a print preview.
What user need is that the script would be printed as according to the user enters the page number range like for example
page 1-12 and the form would be printed from page 1 to 12.
can anyone help me out with the problem ASAP.
thankx & rgds
TCL kolkata

Hi!
&PAGE& variable gives you the actual page.
/E MYELEMENT
/: DEFINE &MYPAGE& = &PAGE&
I hope it works...
Regards
Tamá

Similar Messages

  • Page number after printing a text element in SAPScript

    Hello to all,
    is it possible to know the page number in which SAPScript print a text element?
    Thanks and regards
    Franco

    Hi!
    &PAGE& variable gives you the actual page.
    /E MYELEMENT
    /: DEFINE &MYPAGE& = &PAGE&
    I hope it works...
    Regards
    Tamá

  • Page number is printing reverse

    Hi Experts,
    i have one problem in smart forms  that is i have to print 16 pages, in the output the total number pages shwoing reverse like this
    " page 1 of 61 , page 2 of 61 ..................page 16 of 61 "  this is wrong .. iam using  Page:&SFSY-PAGE& of &SFSY-FORMPAGES(3ZC)&  this code .  Please send the solution for this . Rewards are helpful answers.
    Thanks & Regards,
    N.Narasimha Rao.

    Hi,
    Check out with this,
    &SFSY-PAGE& of &SFSY-FORMPAGES&  i.e. remove 3ZC.
    It should work.
    Thanks.
    Swati

  • I can't select just one page number to print from a document. It prints the whole document.

    how do i print one page out of several pages?

    If the PDF page content is an image (for text that'd by the image that any scanner provides) then it is an image that exports to Word.
    Regardless, Adobe Reader cannot export PDF page content, cannot create PDF and cannot manipulate PDF page content.
    Adobe Reader is a PDF viewer only.
    Perhaps you have a subscription to one of Adobe's online subscription services.
    (ExportPDF, PDF Pack, etc.)
    Each of the online subscription services have their own dedicated user-2-user forums.
    Easy find as there here in Adobe's Forums. Hmmm, just dumping somewhere means ... Ah well, won't go there. Miss Manners would not approve eh.
    Resources for getting into a dialog with Adobe:
    (other than the user-2-user forums)
    ~~~~~~~~~
    To contact support for acrobat.com subscription services: 
    https://www.acrobat.com/misc/en/contact-support.html 
    Other links to support:
    http://helpx.adobe.com/contact.html
    http://helpx.adobe.com/support.html
    contact Adobe Customer Care on Twitter @AdobeCare.
    Phone support (for a fee - have credit card ready)
    800-833-6687, Mon - Fri, 5AM - 7PM PT 
    Be well...

  • With newest version of numbers how do you remove the page number when printing?

    I have the newest versin of numbers, just downladed it and now i can't get rid of the page numbering when i go to print??  Please help

    Thank You.  That was so simple.  Just in the other version you could just click it off.  I appreciate the help

  • Page number not printing on last page

    Hi all,
    I am ablt to print the total no of pages  in all pages ecept the last page.
    whats wromg in my code ?
    REPORT  ZDEMO_EOF NO STANDARD PAGE HEADING LINE-SIZE 100 line-count 27(2).
    types: BEGIN OF t_mara,
            matnr TYPE mara-matnr,
            ernam type mara-ernam,
           end of t_mara.
    data: itab TYPE TABLE OF t_mara,
          wa TYPE t_mara.
    select matnr ernam FROM mara INTO TABLE itab
      WHERE matnr BETWEEN '000000000000000001' and '000000000000000777'.
      sort itab by matnr.
      delete itab WHERE matnr is INITIAL.
      LOOP AT itab INTO wa .
        WRITE:/ sy-tabix,'!', wa-matnr, wa-ernam.
      ENDLOOP.
      data: v TYPE n.
      v = sy-linct - sy-linno.
      skip v.
    end-OF-PAGE.
      data: zline type i,
            temp TYPE f,
            zpages TYPE i,
            temp1 TYPE i.
      CLEAR: zline,temp,zpages,temp1.
    DESCRIBE TABLE itab LINES zline.
    temp = zline / sy-srows.
    zpages = TRUNC( temp ).
    temp1 = FRAC( temp ).
    if temp1 > 0.
    zpages = zpages + 1.
    endif.
    write: /'Page ',sy-pagno, ' of ', zpages RIGHT-JUSTIFIED.
    Thanks in advance
    krupali

    hi ,
    TYPES: BEGIN OF t_mara,
    matnr TYPE mara-matnr,
    ernam TYPE mara-ernam,
    END OF t_mara.
    DATA: itab TYPE TABLE OF t_mara,
    wa TYPE t_mara.
    SELECT matnr ernam FROM mara INTO TABLE itab
    WHERE matnr BETWEEN '000000000000000001' AND '000000000000000777'.
    SORT itab BY matnr.
    DELETE itab WHERE matnr IS INITIAL.
    DATA: v TYPE i.
    v = sy-linct - sy-linno.
    LOOP AT itab INTO wa .
      WRITE:/ sy-tabix,'!', wa-matnr, wa-ernam.
    ENDLOOP.
    RESERVE v LINES.  "-----> reserve lines
    *SKIP v.
    END-OF-PAGE.
      DATA: zline TYPE i,
      temp TYPE f,
      zpages TYPE i,
      temp1 TYPE i.
      CLEAR: zline,temp,zpages,temp1.
      DESCRIBE TABLE itab LINES zline.
      temp = zline / sy-srows.
      zpages = TRUNC( temp ).
      temp1 = FRAC( temp ).
      IF temp1 > 0.
        zpages = zpages + 1.
      ENDIF.
      WRITE: /'Page ',sy-pagno, ' of ', zpages RIGHT-JUSTIFIED.
    Thanks & Regards

  • Blank page in cheque printing using sapscript

    hi,
    i've created a Z script for cheque printing copying the standard script and driver program remains RFFOUS_C. I've deleted all windows except CHECK and MAIN. In main, i've commented all code and elements. In check, i've added my own code to print cheque details and rest everything else is commented. There are no blank lines in either of the windows. There is only 1 page i.e. FIRST in the script and no next page. After all this i'm still getting an extra balnk page after i get cheque details on 1st page. i'm using Transaction F110 to generate the cheque.
    Please suggest what can be done in such a case. Do i need to make changes in std program RFFOUS_C for this??
    Thanks!

    Hi,
    Are there any blank data in the internal table which is used for printing. Also check whether there are any othere details like text elment after printing check details
    Thanks
    kamath

  • Page number problem while printing

    We are unable to get the page number while printing from SAP, we are trying to print a word document from SAP and when it prints the page numbers do not appear properly. if we save the document to the desktop and print, it prints properly.
    We print to a Xerox 7345 printer...we have loaded the exact driver, but still does not print. Can anything be done from UNIX side for this.
    the page number appear as 0/9 0/9...where it should appear as 1/9, 2/9..etc..
    Any help is highly appreciated, Hope there are some good Basis guys out here.

    Hi Aakash,
    Is it from report or SAP Script?
    Regards,
    Atish

  • For each loop start on odd page number

    Hy,
    I've an rtf template with a for each loop. I want to skip a page between each loop and to start each new loop on an odd page number (duplex printing). It's easy to skip a page but i don't know how to start each loop on an odd page. i've tried this before or after my for-each
    <?section:force-page-count;'end-on-even-layout'?>
    but it doesn't work for me.
    Sorry for my english
    regards

    One way of doing this is to create an object (B_1) at the end of the report and only have the object print if the current page is an odd page.
    - To force the page break, you need to set the "page break before" property against "B_1".
    - To test the page number in the format trigger use the srw.get_page_num(page_num out number) built-in function.
    You need to make sure that "B_1" is formatted after all the other objects in the layout. One way of ensuring this is to create a frame around all the other objects and make the frame variable. Any objects that come below the frame will be formatted after the variable frame.
    There is still the issue of any margin objects. Since margin objects print before any objects in the body, your margin objects will still print in the overflow page. However, this may be what you want if you're printing the page number in the margin.

  • Printing  page number and continu text in sap script

    Hi
      I have created sapscript to print PO and using standard print program with three pages.
    My thrid page called with NEWPAGE <> from Main window of first or sencond page wokign fine but the page number is coming like page 1 of 2, 2 of 2 and 3 of 2
    another issue: I want to print continue text if sapscript has more than one page, Not included last above newpage <page>
    Please give me some idea how to go about above two
    Regrads,
    challa

    Hello,
    TO print the page number do like this
    <b>&Pages& of &SAPSCIPTS-FORMPAGES&</b>
    To print continues pages. Put the text in the <b>MAIN</b> Page.
    and use <b>PROTECT ..... ENDPROTECT</b>
    If useful reward.
    Vasanth

  • IS-U print workbench - User exit - to get current page number

    Hi,
    I have a doubt in IS-U print workbench where in I need to get the current page number which is being processed inside the user exit of the application form.
    I have a user exit called Z_EXIT_150 and here I have a subroutine which is inside the LOOP DOC_ITEM …ENDLOOP.
    Inside the subroutine, I need to get the current script page number.
    There is an option of getting the current page as &PAGE& inside the Script but I need to know the page number inside the exit.
    Do you have any idea of getting the current page number?
    Thanks and Regards,
    Sakthi.

    Hi Sakthi,
    I have also had this problem while working in IS-U Print Workbench but was also unable to solve.  I tried looking into the output_text that is called when reaching an object that references SAPSCRIPT-FORMPAGES but I too could not find a way to save PAGE to a variable for later use.
    The only idea I can think of, although I have not tried, would be to place some sort of counter variable in the BUILD_DOCUMENTS and increment the counter each time there is a successful printout of a header logo or some other object that you expect to see printed on each new page - that way maybe you can determine later in the exit processing what page # you are currently in. 
    I hope this has helped some.  I would be really interested to hear if someone else has a solution of how to access items in the SAPSCRIPT structure from outside of the SAPscript code.
    Regards,
    Geoff

  • Print tpage number/total page number in a report with width more than 240

    Dear all,
    I need to display total page number as following code sample.
    But I need to put it after position 240.
    this program can print total page number if   it is placed at postion 239 or before.
    WRITE: /234(10) 'Heading',  239 SY-PAGNO,'of ', '-----'.
    Whenever I put  240 or more WRITE: /234(10) 'Heading',  240 SY-PAGNO,'of ', '-----'.
    Total page num could not be displayed.
    Please tell me the solution.
    thanks
    REPORT YPAGECOUNT NO STANDARD PAGE HEADING LINE-SIZE 276  LINE-COUNT 65.
        DATA L_PAGE_COUNT(5) TYPE C.
    TOP-OF-PAGE.
      WRITE : /234(10) 'PAGE', SY-PAGNO,'/ ','-----', ''.
       WRITE: /234(10) 'Heading',  239 SY-PAGNO,'of ', '-----'.
        ULINE.
    START-OF-SELECTION.
      Real list output takes place here
        DO 1000 TIMES.
            WRITE: / 'Line #', SY-LINNO.
        ENDDO.
      Page count will be printed on each page here
        WRITE SY-PAGNO TO L_PAGE_COUNT LEFT-JUSTIFIED.
        DO SY-PAGNO TIMES.
            READ LINE 1 OF PAGE SY-INDEX.
            REPLACE '-----' WITH L_PAGE_COUNT INTO SY-LISEL.
            MODIFY CURRENT LINE.
        ENDDO.

    Using Values Greater than 255 for the LINE-SIZE of a List
    If you define a fixed column width greater than 255 using the LINE-SIZE addition in the REPORT or NEW-PAGEstatement, the following notes apply:
    Type definitions: The type group SLIST defines the valid maximum value for the list width (SLIST_MAX_LINESIZE), and contains a type for list lines with maximum width (SLIST_MAX_LISTLINE).
    Accessing the entire contents of a line: To read or modify the entire contents of a wide line, you can use the ... LINE VALUE addition in the READ LINE or MODIFY LINE statements. This is an alternative to using SY-LISEL that is independent of the attributes of the system field (since the length of SY-LISEL is 255 characters).
    Horizontal lines: With extra-wide lists, the "ULINE." statement corresponds to "WRITE / SY-ULINE.". So, for example, "ULINE AT 5(300)." corresponds to "WRITE AT 5(300) SY-ULINE.".
    Output length: You can use the length specification in WRITE (or ULINE) to extend the output length of an extra-wide list up to the value of LINE-SIZE. If you want to output a whole field that is longer than 255 characters, you must use this, even if the field itself is defined as longer than 255 characters.
    Example
    NEW-PAGE LINE-SIZE 1000.
    DATA: F1(500) VALUE 'F1'.
    WRITE: /      F1 COLOR COL_NORMAL.  " Output with length 255
    WRITE: /(500) F1 COLOR COL_NORMAL.  " Output with length 500
    Awrd Points if useful
    Bhupal

  • BI Publisher - if page number is not divisible by 2 then print a blank page

    Hi,
    I have an BI Publisher rtf word template. I want to be able to print a blank page if the page number is not divisible by 2. Does any body know how this can be done? Your input is greatly appreciated and thank you so much in advance.
    MT
    Edited by: user11177994 on Mar 29, 2010 8:19 AM

    Hi Dominic,
    Thank you for the link. The problem that I have is when the job specification last page prints on the front of the page, and the next job specification prints on the back of that page. There is no way I can control what page it is going to print on. This is depending on how much description the user puts in. Any suggestion is greatly appreciated.
    I do have another issue too, and you maybe able to help me with this. Below is a list of form fields on my template. When the job specification is printed on more than one page, I could not get the fk_job_title to print on the continuous pages. Is there a way I can code this fk_job_title to print on all of it's continuos page? I have tried many different ways but could not get it to print. I also posted this in the forum, but didn't get any respond.
    ** form fields **
    CLASS TITLE: F fk_job_title PAY GRADE: p_grade
    JOB CODE: job_code SALARY RANGE: s1 - s2
    LOCATION OF WORK: work_location
    GENERAL DESCRIPTION: general_descr
    ESSENTIAL WORK TASKS: work_task
    KNOWLEDGE, SKILLS, AND ABILITIES: knowledge_skill
    EDUCATIONAL AND EXPERIENCE: education_exp
    SUBSTITUTIONS: sub
    CERTIFICATIONS/LICENSES: certification_license
    OTHER JOB ASPECTS: job_aspect E
    PB
    Thank you so much,
    MT

  • Print Multiple copies of report, and resetting Page number for each copy.

    Dear frnds!
    i am using developer 6i reports i have a problem.
    i want to Print Multiple copies of report, and resetting Page number for each copy" that is 4 copies of an invoice is required
    1 - for user copy
    2- gate copy
    3- accounts office
    4- office copy
    any body please tell me the solution "i am using oracle 9i and developer 6i"
    Thanx
    Ibrar

    Hi,
    I was wondering if you were able to get your multiple copies working? Below is what I have so far, just trying to get it to work before changing the actual template.
    <?for-each-group@section:R5542520/Pick_Slips_Detail_Lines_S3;PickSlipNumber_ID260?>
    <?variable@incontext:G1;R5542520/Pick_Slips_Detail_Lines_S3;PickSlipNumber_ID260?>
    <?for-each@section:xdoxslt:foreach_number($_XDOCTX,1,3,1)?>
    HEADER
    PSN: <?$G1/Pick_Slip_Number_Display_ID54?>
    PSN Detail: <?$G1/PickSlipNumber_ID260?>
    Page 1 of 3
    <?start:body?>
    BODY
    <?$G1/LineNumber_ID6?>
    <?end body?>
    FOOTER
    <?end for-each?>
    <?end for-each-group?>
    XML:
    <R5542520>
    <Pick_Slips_Detail_Lines_S24>
    <Header_Custom_Section_S24>
    <Pick_Slip_Number_Display_ID54>123456</Pick_Slip_Number_Display_ID54>
    <PickSlipNumber_ID260>123456</PickSlipNumber_ID260>

  • How to print out page number

    I want to print page number with every page how it possible.....
    So that I would come to know how many printed documents are left....
    Please reply soon

    Hi Friend,
    In the Live Previewer menu
    on top there are two buttons
    one for Insert date and time
    two for Insert page numbers
    select the second one it will diff
    options for page displaying
    so that u can display the page numbers
    bye
    srini

Maybe you are looking for