Page number in ALV report

Hi all,
I use top of page to print page number for ALV report. When i run my report in backgrond and see the spool, the page is always started from page 2.
These does not happen when I use non-ALV report, report prints the header starting from page 1 normally. It is weird.
does anyone of you ever face such of that problem ?
thanks alots
Alia

Hi Alia,
Page number is usually not set in an ALV display, as compared to  List processing.
r u sure this is a requirement?
chk this:
ALV Print page numbers
Regards,
Anjali

Similar Messages

  • End of Page event in ALV report using SALV class[cl_salv_hierseq_table]

    Hi ,
    have been working on a ALV report using the class SALV cl_salv_hierseq_table
    I am facing few issues pertaining to two things:
    1. Displaying some subtotal text along with the subtotals.
    Example refer the standard demo example: SALV_DEMO_HIERSEQ_FORM_EVENTS
    Now instead of A 17 and A26 I would like to show text like Subtotal for the Carrid.for subtotals and grand totals
    Like   Subtotal for A 17 is :      XXXXXXX
              GrandTotal is         :      YYYYYY
    2. We have a page break and a new page for every purchasing group as in the standard example SALV_DEMO_HIERSEQ_FORM_EVENTS for CARRID.
    I need to display some variable values as number of documents ,total number of records etc at the end of each CARRID group before a new page starts for the next CARRID.Please note i do not want it on every page.it should only be diaplyed at the end of page whose next page would be for next CARRID.[basically at end of every carrid]Example:after displaying all details for AA need to display the number of records for that carrid at the end of the page[as page break is based on CARRID]/
    Thanks
    Jyotsna

    at end of page event, for CL_SALV_EVENTS_HIERSEQ, has some useful parameters allowing to know where you are at the time of event
    parameter VALUE is of type CL_SALV_FORM which contains public attribute IF_SALV_FORM~ACCDESCRIPTION; you can slo get contents of it
    about text of total/subtotal, this is normally set in the layout

  • How to Display Page Numbers in ALV Report HTML End of page Event

    hai Gurus
    Greetings
    Please tell me how to get current page noumber and total number of pages in ALV Report (in HTML End of Page Event)
    i tried with sy-pagno system field but it is not working
    so please guide me
    Thanks
    Ramesh

    check below code....
    *Work area for Layout
         gf_layout       type  slis_layout_alv,
    *Work area for HEADER FOOTER    
         gf_header type slis_listheader,
    *Work area for Field catalogue    
         gf_fieldcat     type  slis_fieldcat_alv.
         it_top_page type slis_t_listheader,
    *Internal table for Field catalogue    
         it_fcat      type slis_t_fieldcat_alv.
    perform:fill_layout,
                  prepare_header,
                  field_catlog,
                  display_report.
         Form  fill_layout
    form fill_layout .
      gf_layout-colwidth_optimize = 'X'.
    endform.                    " fill_layout
         Form  field_catlog
    form field_catlog .
      data : lf_fcat type line of slis_t_fieldcat_alv,
             l_cnt type i.
      clear : lf_fcat, l_cnt.
    Employee Number
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'EMPLID'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 8.
      lf_fcat-seltext_l   = text-003.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Last Name
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'USERNAME'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 20.
      lf_fcat-seltext_l   = text-004.
      append lf_fcat to it_fcat.
    *First Name
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'EMPMAIL'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 40.
      lf_fcat-seltext_l   = text-005.
      append lf_fcat to it_fcat.
    *Known As
      clear  lf_fcat.
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'EMPSTATUS'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 10.
      lf_fcat-seltext_l   = text-006.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *System UserID
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'COSTCENTER'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 10.
      lf_fcat-seltext_l   = text-007.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *EMail ID
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'DEPTDESC'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 8.
      lf_fcat-seltext_l   = text-008.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Employment Status
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'LOC'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 20.
      lf_fcat-seltext_l   = text-009.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Personnel Area
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'TITLE'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 40.
      lf_fcat-seltext_l   = text-010.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Personnel Area Text
      clear  lf_fcat.
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'HDATE'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 10.
      lf_fcat-seltext_l   = text-011.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Country Grouping text
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'MGRID'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 10.
      lf_fcat-seltext_l   = text-012.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Cost Center
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'MGRNAME'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 20.
      lf_fcat-seltext_l   = text-013.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Employee Group
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'MGMAIL'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 40.
      lf_fcat-seltext_l   = text-014.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Organizational Unit
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'DIV'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 25.
      lf_fcat-seltext_l   = text-015.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    *Supervisor
      add 1 to l_cnt.
      lf_fcat-fieldname   = 'BUSUNIT'.
      lf_fcat-tabname     = 'IT_EMPLOYEE'.
      lf_fcat-col_pos     = l_cnt.
      lf_fcat-emphasize   = 'X'.
      lf_fcat-outputlen   = 25.
      lf_fcat-seltext_l   = text-016.
      append lf_fcat to it_fcat.
      clear  lf_fcat.
    endform.                    " field_catlog
         Form  display_report
    form display_report .
      data : l_repid type sy-repid.
      clear l_repid.
      l_repid = sy-repid.
      call function 'REUSE_ALV_GRID_DISPLAY'
        exporting
          i_callback_program          = l_repid
          is_layout                   = gf_layout
          it_fieldcat                 = it_fcat
          i_callback_top_of_page      = 'TOP-OF-PAGE'
        tables
          t_outtab           = it_employee
        exceptions
          program_error      = 1
          others             = 2.
    endform.                    " display_report
         Form  PREPARE_HEADER
    form prepare_header.
      data:l_header1(20),
           l_header2(60).
      data:l_header3(20),
         l_header4(60).
      l_header1       = 'Met Life Census Data'.
      l_header2+40(8) = 'Run Date'.
      write sy-datum to l_header2+50(10).
    header
      gf_header-typ  = 'S'.
      gf_header-key  = l_header1.
      gf_header-info = l_header2.
      append gf_header to it_top_page.
      clear gf_header.
    endform.                    " PREPARE_HEADER
    form top-of-page.
      call function 'REUSE_ALV_COMMENTARY_WRITE'
        exporting
          it_list_commentary = it_top_page.
    endform.                    "TOP-OF-PAGE
    *& Form end_of_list_html
    output at the end of the list - not in printed output *
    FORM END_OF_LIST_HTML USING END TYPE REF TO CL_DD_DOCUMENT.
    DATA: LS_TEXT TYPE SDYDO_TEXT_ELEMENT,
    L_GRID TYPE REF TO CL_GUI_ALV_GRID,
    F(14) TYPE C VALUE 'SET_ROW_HEIGHT'.
    LS_TEXT+0(20) = 'Total Employees'.
    LS_TEXT+40(10) = g_count.
    CALL METHOD END->ADD_TEXT
    EXPORTING
    TEXT = LS_TEXT
    SAP_EMPHASIS = 'STRONG'.
    *adds new line (start new line)
    CALL METHOD END->NEW_LINE.
    CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
    IMPORTING
    e_grid = l_grid.
    CALL METHOD l_grid->parent->parent->(f)
    EXPORTING
    id = 3
    height = 10.
    ENDFORM.

  • How to print Column Labels on each print page of an ALV report

    Hi,
    I have an ALV report which is of 10 print pages.
    I need to print Column Labels on each print page.
    How it is possible.
    Plz write the solution
    Narendra

    Hi Narendra
    try this code.
    reward pts if help.
    Deepanker.
    *& Report  ZDEMO_ALVGRID_EDIT                                          *
    *& Example of a simple ALV Grid Report                                 *
    *& The basic ALV grid, Enhanced to display specific fields as          *
    *& editable depending on field value                                   *
    REPORT  ZDEMO_ALVGRID_EDIT                 .
    TABLES:     ekko.
    TYPE-POOLS: slis.                                 "ALV Declarations
    *Data Declaration
    TYPES: BEGIN OF t_ekko,
      ebeln TYPE ekpo-ebeln,
      ebelp TYPE ekpo-ebelp,
      statu TYPE ekpo-statu,
      aedat TYPE ekpo-aedat,
      matnr TYPE ekpo-matnr,
      menge TYPE ekpo-menge,
      meins TYPE ekpo-meins,
      netpr TYPE ekpo-netpr,
      peinh TYPE ekpo-peinh,
      field_style  TYPE lvc_t_styl, "FOR DISABLE
    END OF t_ekko.
    DATA: it_ekko TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
          wa_ekko TYPE t_ekko.
    *ALV data declarations
    DATA: fieldcatalog TYPE slis_t_fieldcat_alv WITH HEADER LINE.
    DATA: it_fieldcat TYPE lvc_t_fcat,     "slis_t_fieldcat_alv WITH HEADER LINE,
          wa_fieldcat TYPE lvc_s_fcat,
          gd_tab_group TYPE slis_t_sp_group_alv,
          gd_layout    TYPE lvc_s_layo,     "slis_layout_alv,
          gd_repid     LIKE sy-repid.
    *Start-of-selection.
    START-OF-SELECTION.
      PERFORM data_retrieval.
      PERFORM set_specific_field_attributes.
      PERFORM build_fieldcatalog.
      PERFORM build_layout.
      PERFORM display_alv_report.
    *&      Form  BUILD_FIELDCATALOG
          Build Fieldcatalog for ALV Report
    FORM build_fieldcatalog.
      wa_fieldcat-fieldname   = 'EBELN'.
      wa_fieldcat-scrtext_m   = 'Purchase Order'.
      wa_fieldcat-col_pos     = 0.
      wa_fieldcat-outputlen   = 10.
      wa_fieldcat-emphasize   = 'X'.
      wa_fieldcat-key         = 'X'.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'EBELP'.
      wa_fieldcat-scrtext_m   = 'PO Item'.
      wa_fieldcat-col_pos     = 1.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'STATU'.
      wa_fieldcat-scrtext_m   = 'Status'.
      wa_fieldcat-col_pos     = 2.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'AEDAT'.
      wa_fieldcat-scrtext_m   = 'Item change date'.
      wa_fieldcat-col_pos     = 3.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'MATNR'.
      wa_fieldcat-scrtext_m   = 'Material Number'.
      wa_fieldcat-col_pos     = 4.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'MENGE'.
      wa_fieldcat-scrtext_m   = 'PO quantity'.
      wa_fieldcat-col_pos     = 5.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'MEINS'.
      wa_fieldcat-scrtext_m   = 'Order Unit'.
      wa_fieldcat-col_pos     = 6.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'NETPR'.
      wa_fieldcat-scrtext_m   = 'Net Price'.
      wa_fieldcat-edit        = 'X'. "sets whole column to be editable
      wa_fieldcat-col_pos     = 7.
      wa_fieldcat-outputlen   = 15.
      wa_fieldcat-datatype     = 'CURR'.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
      wa_fieldcat-fieldname   = 'PEINH'.
      wa_fieldcat-scrtext_m   = 'Price Unit'.
      wa_fieldcat-col_pos     = 8.
      APPEND wa_fieldcat TO it_fieldcat.
      CLEAR  wa_fieldcat.
    ENDFORM.                    " BUILD_FIELDCATALOG
    *&      Form  BUILD_LAYOUT
          Build layout for ALV grid report
    FORM build_layout.
    Set layout field for field attributes(i.e. input/output)
      gd_layout-stylefname = 'FIELD_STYLE'.
      gd_layout-zebra             = 'X'.
    ENDFORM.                    " BUILD_LAYOUT
    *&      Form  DISPLAY_ALV_REPORT
          Display report using ALV grid
    FORM display_alv_report.
      gd_repid = sy-repid.
    call function 'REUSE_ALV_GRID_DISPLAY'
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY_LVC'
           EXPORTING
                i_callback_program      = gd_repid
               i_callback_user_command = 'USER_COMMAND'
                is_layout_lvc               = gd_layout
                it_fieldcat_lvc             = it_fieldcat
                i_save                  = 'X'
           TABLES
                t_outtab                = it_ekko
           EXCEPTIONS
                program_error           = 1
                OTHERS                  = 2.
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " DISPLAY_ALV_REPORT
    *&      Form  DATA_RETRIEVAL
          Retrieve data form EKPO table and populate itab it_ekko
    FORM data_retrieval.
      SELECT ebeln ebelp statu aedat matnr menge meins netpr peinh
       UP TO 10 ROWS
        FROM ekpo
        INTO  CORRESPONDING FIELDS OF TABLE it_ekko.
    ENDFORM.                    " DATA_RETRIEVAL
    *&      Form  set_specific_field_attributes
          populate FIELD_STYLE table with specific field attributes
    form set_specific_field_attributes .
      DATA ls_stylerow TYPE lvc_s_styl .
      DATA lt_styletab TYPE lvc_t_styl .
    Populate style variable (FIELD_STYLE) with style properties
    The NETPR field/column has been set to editable in the fieldcatalog...
    The following code sets it to be disabled(display only) if 'NETPR'
    is gt than 10.
      LOOP AT it_ekko INTO wa_ekko.
        IF wa_ekko-netpr GT 10.
          ls_stylerow-fieldname = 'NETPR' .
          ls_stylerow-style = cl_gui_alv_grid=>mc_style_disabled.
                                                 "set field to disabled
          APPEND ls_stylerow  TO wa_ekko-field_style.
          MODIFY it_ekko FROM wa_ekko.
        ENDIF.
      ENDLOOP.
    endform.                    " set_specific_field_attributes
    pls reward pts is help,

  • End-of-page event in alv report

    Hi all,
    I want to create end-of-page in alv report i have used event also
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY' * "
       EXPORTING *
         i_callback_program                = sy-repid * "
         i_callback_user_command           = 'USER_COMMAND' * "
         i_callback_top_of_page            = 'TOP_OF_PAGE' * "
       I_STRUCTURE_NAME                  = * "
         it_fieldcat                       = fcat[] * "
         it_events                         = it_event[] * "
        TABLES
          t_outtab                          = gtbl_pohead * "
       EXCEPTIONS
         program_error                     = 1 * "
         OTHERS                            = 2 "
    FORM end_of_page.  *
      DATA:   listwidth TYPE i, *
              ld_pagepos(10) TYPE c, *
              ld_page(10)    TYPE c. *
      WRITE: sy-uline(50). "
      SKIP 3.
      WRITE:/40 'Page No',sy-pagno. "
    ENDFORM.                    "END_OF_PAGE "

    hi
    Search in SDN.You can find the solution for this.Before posting please search in SDN.
    You have to use this  FM 'REUSE_ALV_EVENTS_GET'
    [End-Of-Page|http://www.sapdev.co.uk/reporting/alv/alvgrid_events.htm]
    [Endo Of Page|http://www.sdn.sap.com/irj/scn/advancedsearch?query=alvend-of-pageevent+]

  • Problem with Page Break In ALV Report

    Hi
    I have got a problem in my ALV report. I have a checkbox in the user input screen where users decide whether they want a page break or not in the print preview (or print) page. Now i also have the option to have layout name in the input screen. so If i leave the layout box empty the check or not check of page break works fine. but if use a save layout name in the layout box the add check box doesn't work anymore. If i have a layout name in the layout box it doesn't matter whether i have checked for page break or not it does the same thing.(in one report it always puts the page breaked)
    Any ideas where to look for the error?
    here is the code for the page break. Opt5 is the check box.
      perform build_sort tables pt_sort changing ls_sort.
      ls_sort-fieldname = 'PERNR'.
      ls_sort-subtot    = 'X'.
    IF OPT5 = 'X'.
       ls_sort-GROUP = '*'.
      ENDIF.
      append ls_sort to pt_sort.
      ls_sort-subtot    = ' '.
      ls_sort-GROUP = ''.

    Never mind it was acting like the page break was not working because the layout was saved with the page break on/OFF.

  • 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

  • Line-count/page number in alv

    My report is a z copy of FBL5N .In that i wud have included the page no as a part of the heading , my issue is, since it is display some other information like customerr number company code name etc., my page no will also display only if the top_of_page event is called , but this will be called only if the info related to the first customer is printed it will call the event again say for example like my inpur is for customer a customer b company code a company code b if the records for customer a and company code a combination is over it will call the top-of-page event again so it doesnt matter for any number of number say like it can even have 100's of records in the display for this entire 100 records my page number will be displayed as 1 for the next combination it will be displayed as 2 but when i try to take the printed copy 100 number of records cannot be displayed in a single sheet in that case my page number shud vary but since the top-of-page event is called only once for the entire 100 records it is displaying repeatedly as 1 only how can i sove it

    Hi,
    check the following link:
    http://www.sapbrain.com
    regards,
    bhaskar

  • How do I change the start page number in crystal report ?

    hi all
    i have report
    I want to do change the page number 1 and make it 5
    any help please
    thank you all

    Hi,
    Page number always start with 1 if you want to your page number to start with 5 then try this formula in place of your page number special field :
    Whileprintingrecords;
    Numbervar x:=4;
    x:=x+1;
    This will print 5 on your first page.
    Thanks,
    Sastry

  • Which variable gives the Total Page Number in a report

    Which variable of Report can give me the total number of Pages. I want this information on first page itself. I want to refer this value in pl/sql thus i want to access the value programatically, and not just show in report as Page 1 of 10.
    Thanks,
    Sudhanshu

    This may help you! This is straight from the Help in Reports! More about this can be found by searching for Physical PAges in Reports Help!
    Suppose that you want to have the page number at the top of each page of your report. Furthermore, you want the page number to be of the form "Page n of m pages":
    1 Create a field named F_PAGE and set the Source property to &Physical Page Number.
    2 In the Field Property Palette, set the Page Numbering property by filling out the Page Numbering dialog box as follows:
    -Check Main Section and uncheck Header Section and Trailer Section because you only want to number the Main Section pages.
    -Type 1 in the Start At setting.
    -Type 1 in the Increment By setting.
    -Type &Report under Reset At because you don't want the page numbers to reset to zero until the report is done.
    3 Create a field called F_TOTPGE and set the Source property to &Total Number of Physical Pages.
    4 Do either of the following:
    -Hide these fields (i.e., set the Visible property to No) and reference them within boilerplate text:
    Page &F_PAGE of &F_TOTPGE
    -Alternatively, position F_PAGE and F_TOTPGE beside each other. Insert boilerplate to the left of F_PAGE that contains the text "Page". Insert boilerplate between F_PAGE and F_TOTPGE that contains the text "of".
    null

  • How to disable showing page number on oracle report

    Hi,
    when i am using ttitle and btitle options in oracle report, page number & date gets automatically added top of my report. Is there any option if i don't want these two to appear on my report. how can i disable them.

    Hi,
    user8531525 wrote:
    Hi,
    when i am using ttitle and btitle options in oracle report, page number & date gets automatically added top of my report. Is there any option if i don't want these two to appear on my report. how can i disable them.When you use the word "report", people (like Tubby) are likely to think you are using Oracle Reports, rather than SQL*Plus. Avoid the word "report", or else make it clear what you're doing.
    By default, TTITLE puts the date on the left, and the page number on the right.
    If you don't want them, put something else there. Explicitly put an empty string there, if you don't want anything else:
    TTITLE  LEFT ""   CENTER "Monthly Firbolig Summary"   RIGHT ""

  • Help needed- Reg: Display page number in SQL Reports

    Hi,
    I need to display page number in " page no: X of Y " format where X is current page & Y is total number of pages. Now I am able to display only the current page using ' sql.pno '. but not able to display in ' X of Y ' format.
    Any inputs in this regard will be helpful.
    Thanks & Regards,
    Anilkumar.

    Hello Anil,
    If you have the above requirement for Oracle Reports then follow the steps:
    1.In the Paper Layout view or Paper Design view, choose InsertPage Number.
    2. In the Insert Page Number dialog box, choose from the list the location for the page number.
    3.Click the desired page number format: Page Number Only or Page Number and Total Pages.
    Cheers,
    Suresh

  • Displaying page number in ALV grid display

    Hi,
    Is it possible to display page number in an ALV grid display?
    If yes, how?
    I tried it in top of page event, but it didnt work.
    Harmeet.

    hi,
    check out the sample code....
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
          EXPORTING
            i_callback_program          = sy-repid
            i_callback_user_command     = 'F00007_USER_COMMAND'
            i_callback_html_top_of_page = 'HTML_TOP_OF_PAGE'
            it_fieldcat                 = g_t_fieldcat[]
            it_events                   = gt_events[]
            i_save                      = 'A'
          TABLES
            t_outtab                    = g_t_final_report[]
          EXCEPTIONS
            program_error               = 1
            OTHERS                      = 2.
        IF sy-subrc <> 0.
          MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                  WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        ENDIF.
          FORM TOP_OF_PAGE                                              *
    FORM top_of_page.
    write : sy-pagno.
    ENDFORM.                    "top_of_page
    Reward Appropriate points.
    Regards,
    Mansi.

  • Display Page number in ALV List.

    Dear Friends,
        I want to display page numbers in ALV list print output. But I dont know how to do that without using objects.
    Please suggest.
    Regards,
    Madan.

    TRY LIKE THIS
    data : ifieldcat type slis_t_fieldcat_alv,
           wfieldcat type slis_fieldcat_alv,
           IEVENT TYPE SLIS_T_EVENT,
           WEVENT TYPE SLIS_ALV_EVENT..
    CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
    EXPORTING
       I_LIST_TYPE           = 0
    IMPORTING
       ET_EVENTS             = IEVENT
    EXCEPTIONS
      LIST_TYPE_WRONG       = 1
      OTHERS                = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    READ TABLE IEVENT INTO WEVENT WITH KEY NAME = 'TOP_OF_PAGE'.
    IF SY-SUBRC EQ 0.
    WEVENT-FORM = 'TOP_OF_PAGE'.
    MODIFY IEVENT FROM WEVENT INDEX SY-TABIX.
    ENDIF.
    CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
    EXPORTING
      I_INTERFACE_CHECK                 = ' '
      I_BYPASSING_BUFFER                =
      I_BUFFER_ACTIVE                   = ' '
       I_CALLBACK_PROGRAM                = REPID
      I_CALLBACK_PF_STATUS_SET          = ' '
      I_CALLBACK_USER_COMMAND           = ' '
      I_CALLBACK_TOP_OF_PAGE            = 'TOPOFPAGE'
      I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
      I_CALLBACK_HTML_END_OF_LIST       = ' '
      I_STRUCTURE_NAME                  =
      I_BACKGROUND_ID                   = ' '
      I_GRID_TITLE                      =
      I_GRID_SETTINGS                   =
      IS_LAYOUT                         =
       IT_FIELDCAT                       = IFIELDCAT
      IT_EXCLUDING                      =
      IT_SPECIAL_GROUPS                 =
      IT_SORT                           =
      IT_FILTER                         =
      IS_SEL_HIDE                       =
      I_DEFAULT                         = 'X'
      I_SAVE                            = ' '
      IS_VARIANT                        =
       IT_EVENTS                         = IEVENT
      IT_EVENT_EXIT                     =
      IS_PRINT                          =
      IS_REPREP_ID                      =
      I_SCREEN_START_COLUMN             = 0
      I_SCREEN_START_LINE               = 0
      I_SCREEN_END_COLUMN               = 0
      I_SCREEN_END_LINE                 = 0
      IT_ALV_GRAPHICS                   =
      IT_ADD_FIELDCAT                   =
      IT_HYPERLINK                      =
      I_HTML_HEIGHT_TOP                 =
      I_HTML_HEIGHT_END                 =
      IT_EXCEPT_QINFO                   =
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER           =
      ES_EXIT_CAUSED_BY_USER            =
      TABLES
        T_OUTTAB                          = ITAB
    EXCEPTIONS
      PROGRAM_ERROR                     = 1
      OTHERS                            = 2
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    FORM TOP_OF_PAGE.
    WRITE : /10 'HeadinG OF ALV'.
    WRITE : 100 SY-PAGNO.
    ENDFORM.
    ONE THING IS THERE YOU CAN USE WRITE FOR ONLY LIST DISPLAY NOT FOR GRID DISPALY.
    REGARDS
    SHIBA DUTTA

  • Page Number in Normal Report List?

    Is this possible? How? I need to put like Page 1 of 1 on the lower right hand corner of the report page.
    Thanks rewards will be given

    HI
    see this report
    page number is there, just adjust the place of possition 
    REPORT  ZNNR_REPORT NO STANDARD PAGE HEADING MESSAGE-ID ZNNR LINE-SIZE 100 LINE-COUNT 65(4).
    ******DATA DECLARATIONS**********
    DATA : BEGIN OF IT_PLANT OCCURS 0,
            MATNR LIKE MARA-MATNR,
            WERKS LIKE MARC-WERKS,
            PSTAT LIKE MARC-PSTAT,
            EKGRP LIKE MARC-EKGRP,
           END OF IT_PLANT.
    DATA : BEGIN OF IT_PONO OCCURS 0,
            EBELN LIKE EKKO-EBELN,
            EBELP LIKE EKPO-EBELP,
            MATNR LIKE EKPO-MATNR,
            WERKS LIKE EKPO-WERKS,
            LGORT LIKE EKPO-LGORT,
           END OF IT_PONO.
    TABLES EKKO.
    ********END OF DATA DECLARATIONS*********
    ********SELECTION SCREEN DESIGN ***********
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    PARAMETER : P_WERKS LIKE MARC-WERKS MODIF ID S1.
    SELECT-OPTIONS : S_EBELN FOR EKKO-EBELN NO INTERVALS MODIF ID S2.
    SELECTION-SCREEN END OF BLOCK B1.
    SELECTION-SCREEN BEGIN OF BLOCK B2 WITH FRAME TITLE TEXT-004.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R1 RADIOBUTTON GROUP G1 DEFAULT 'X'.
    SELECTION-SCREEN COMMENT 5(20) TEXT-002 FOR FIELD R1.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : R2 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN COMMENT 5(20) TEXT-003 FOR FIELD R2.
    SELECTION-SCREEN END OF LINE.
    SELECTION-SCREEN END OF BLOCK B2.
    ******END OF SELECTION SCREEN DESIGN****************
    *********INITIALIZATION OF SELECTION SCREEN ELEMENTS.*****
    INITIALIZATION.
    P_WERKS = '1000'.
    S_EBELN-LOW = '4500016926'.
    S_EBELN-OPTION = 'EQ'.
    S_EBELN-SIGN = 'I'.
    APPEND S_EBELN.
    CLEAR S_EBELN.
    ************END OF INITIALIZATION***********************
    ***********SCREEN MODIFICATIONS*******************
    AT SELECTION-SCREEN OUTPUT.
      LOOP AT SCREEN.
        IF R1 EQ 'X' AND SCREEN-GROUP1 EQ 'S2'.
          SCREEN-INPUT = 0.
          MODIFY SCREEN.
        ENDIF.
        IF R2 EQ 'X' AND SCREEN-GROUP1 EQ 'S1'.
          SCREEN-INPUT = 0.
          MODIFY SCREEN.
        ENDIF.
      ENDLOOP.
    ********END OF SCREEN MODIFICATIONS*****************
    ***************SCREEN VALIDATIONS *****************
    at selection-screen.
      SELECT SINGLE *
               FROM EKKO
               INTO EKKO
               WHERE EBELN IN S_EBELN.
      IF SY-SUBRC <> 0.
        SET CURSOR FIELD 'S_EBELN-LOW'.
        MESSAGE E999 WITH TEXT-005.
      ENDIF.
    ********end of screen validation*****************
    START-OF-SELECTION.
    *set pf-status '100'.
      IF R1 EQ 'X'.
        SELECT MATNR
               WERKS
               PSTAT
               EKGRP
           FROM MARC
           INTO TABLE IT_PLANT
           WHERE WERKS = P_WERKS.
        LOOP AT IT_PLANT.
          WRITE : SY-VLINE , 2 IT_PLANT-MATNR COLOR COL_KEY,
                 21 SY-VLINE , 22  IT_PLANT-WERKS COLOR COL_KEY,
                 27 SY-VLINE ,28 IT_PLANT-PSTAT COLOR COL_NORMAL,
                 43 SY-VLINE ,44 IT_PLANT-EKGRP COLOR COL_NORMAL.
        ENDLOOP.
      ENDIF.
      IF R2 EQ 'X'.
        SELECT EBELN EBELP MATNR WERKS LGORT
               FROM EKPO
               INTO TABLE IT_PONO
               WHERE EBELN IN S_EBELN.
        LOOP AT IT_PONO.
          WRITE : SY-VLINE , 2 IT_PONO-EBELN COLOR COL_KEY,
                 12 SY-VLINE , 13 IT_PONO-EBELP COLOR COL_KEY,
                 18 SY-VLINE , 19 IT_PONO-MATNR COLOR COL_NORMAL,
                 37 SY-VLINE , 38 IT_PONO-WERKS COLOR COL_NORMAL,
                 44 SY-VLINE , 45 IT_PONO-LGORT COLOR COL_NORMAL, 49 SY-VLINE..
        ENDLOOP.
      ENDIF.
    TOP-OF-PAGE.
      IF R1 EQ 'X'.
    *ULINE AT /1(48).
        WRITE : SY-VLINE ,2 'MATERIAL NUMBER',
                21 SY-VLINE , 22 'PLANT',
                27 SY-VLINE , 28 'STATUS',
                43 SY-VLINE , 44 'GRUP', 48 SY-VLINE.
        ULINE AT /1(48).
      ENDIF.
      IF R2 EQ 'X'.
        WRITE : SY-VLINE , 2 'PO NUMBER',
               12 SY-VLINE, 13 'ITEM',
               18 SY-VLINE,19 'MATERIAL NUMBER',
               37 SY-VLINE, 38 'PLANT',
               44 SY-VLINE, 45 'GRUP',
               49 SY-VLINE.
        ULINE AT /1(50).
      ENDIF.
    <b>END-OF-PAGE.
      ULINE AT /1(50).
      WRITE :/10 'PAGE NUMBER', SY-PAGNO.</b>
    <b>Reward if usefull</b>

Maybe you are looking for

  • Displaying a photo obtained from SAP R/3  in a Web Application Module

    Hi, I am currently developing a Web Application Module (through NWDS) which displays details of employees (name, last name, picture, etc...) obtained from a RFC function module called remotely through SAP JCA connector. I could obtain the picture pas

  • Messages are getting lost during server restart

    Hi, we have a clustered environment. soa_server1, soa_server2, soa_server3 and osb_server1, osb_server2, osb_server3 Queues are configured on each server. Overall process flow is (JMS Queue (configrued in soa_server1) --> BPEL --> mediator -->JMS (co

  • Re: field exits

    Hi,    Iam getting one problem while creating field exit for tcode iw21.  When i choose the activiteis tab, if there is no value in the table control first field then i raise error message( there is no activities defined) . But the error messge is re

  • Captivate crashing repeatedly

    I'm having a horrible time trying to get a project finished with Captivate 4. The project is large - 104 slides, has a TOC and some question slides. But even without the TOC or question slides, even when it was about 10 slides shorter, this project k

  • I am unable to receive or send emails, have apple mail version 4.6 (1085) and snow leopard, OSX 10.6.8

    I am unable to receive or send emails, have apple mail version 4.6 (1085) and snow leopard, OSX 10.6.8, MacBook Incoming mail server "mail.me.com" is greyed out How do I resolve this problem? All help appreciated [email protected]