How doi print Any variable at the end of page in ALV report?

Hi,
Anyone can tell me that How do i print Any variable at the end of page in ALV report?
Exmale: at the ende of alv report i want to print total no of employee who has taken house loan or education loan.

Hi,
Go through these links
Thread in sdn regarding FOOTER IN ALV
[ALV  FOOTER;
Wiki in sdn regarding HEADER AND FOOTER IN ALV
[https://wiki.sdn.sap.com/wiki/display/Snippets/ABAP%20Objects%20-%20ALV%20Model%20-%20Using%20Header%20and%20Footer]
Header and Footer in ALV
[http://www.sap-img.com/abap/test-alv-display-with-header-footer.htm]
Hope this helps.
Thank you,
Pavan.

Similar Messages

  • SAPSCript how to print  a comment at the end of main window on first page?

    In SAP Scripts, How do I print a comment at the end of the first page (I have several pages of data) in the main window?
    - Ven

    hi
    good
    yes we can put condition.....to display the footer window get printed after all data in main window gets over.........................assingn u r footer window to next page [ i.e u r second page] ...and write the condition
    In such senario no need to use a window for footer.
    In the Script form:
    -> In the Main Window itself after all the main data create an Element.
    -> Use BOTTOM and END-BOTTOM; write your footer information between them.
    In your Driver Program:
    -> After printing all the data (means after passing to form and before closing the form) call one WRITE-FORM with the footer element.
    I'm sure it will work.
    f u r not interested to change the print program. Then simply insert simple code in the footer wondow.
    now insert this code in ur footer window
    IF &TTXSY-PAGE& = &SAPSCRIPT-FORMPAGES&.
    *all code in footer goes here.
    ENDIF.
    &TTXSY-PAGE& holds the page number of current page.
    &SAPSCRIPT-FORMPAGES& holds total form pages.
    This will work.
    write this code then the footer will be printed in last page itself
    /: IF &NEXTPAGE& EQ 0
    whatever footer you want.
    /: ENDIF
    You need to create an element in the MAIN window. You can do it in two ways:
    1. In SE71, you can create:
    /:E FOOTER
    /:BOTTOM
    Text
    /:ENDBOTTOM
    In the print program, just call this element.
    2. In you print program, populate parameter type = BOTTOM in FM, WRITE_FORM.
    Ex.
    CALL FUNCTION 'WRITE_FORM'
    EXPORTING
    element = 'FOOTER'
    type = 'MAIN'
    window = 'BOTTOM'
    EXCEPTIONS....
    However, if you issue new page having new header data. Thus, new item data. And if it will exceed more than 1 page, the footer will still appear. To solve this, you need to create a new element in MAIN. Ex. INIT_FOOTER. It just contains the following:
    /:E INIT_FOOTER
    /:BOTTOM
    /:ENDBOTTOM
    Call this after passing all item data.
    reward point if helpful.
    thanks
    mrutyun^

  • End of page in alv report

    hi..
    i want to put end-of-page in my alv report.
    how can i do it??

    This is example for ALV report which has End of Page.....
    REPORT  ZALV1.
    ******************TABLE DECLARATION***********************************
    TABLES : VBAP.                    " tables declaration
    *****************TYPE POOLS*******************************************
    TYPE-POOLS : SLIS.                " slis type pool
    *****************INTERNAL TABLE DECLARATION***************************
    DATA : BEGIN OF IT_VBAP OCCURS 0,
    " internal table for sales document item
          VBELN LIKE VBAP-VBELN,      " sales document
          POSNR LIKE VBAP-POSNR,      " document item
          ERNAM LIKE VBAP-ERNAM,
          " name of the person who created the object
          ERDAT LIKE VBAP-ERDAT,      " date on which the record was created
          MATNR LIKE VBAP-MATNR.      " material number
    DATA : END OF IT_VBAP.
    DATA : BEGIN OF IT_MARA OCCURS 0, " general material data
           MATNR LIKE MARA-MATNR,     " material number
           ERNAM LIKE MARA-ERNAM,
           " name of the person who created the object
           MATKL LIKE MARA-MATKL,     " material group
           MEINS LIKE MARA-MEINS,     " base unit of measure
           PSTAT LIKE MARA-PSTAT.     " maintainence status
    DATA : END OF IT_MARA.
    ******************VARIABLE
    DECLARATION**********************************
    DATA : REPID LIKE SY-REPID.       " program name
    DATA : IT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
    " field catalog table for vbap
           WA_FIELDCAT TYPE SLIS_FIELDCAT_ALV.
    DATA : IT_FIELDCAT1 TYPE SLIS_T_FIELDCAT_ALV,
    " field catalog table for mara
           WA_FIELDCAT1 TYPE SLIS_FIELDCAT_ALV.
    DATA : WA_LAYOUT TYPE SLIS_LAYOUT_ALV.
    DATA: GT_XEVENTS TYPE SLIS_T_EVENT.
    DATA: GT_YEVENTS TYPE SLIS_T_EVENT.            " events table
    DATA : XS_EVENT  TYPE SLIS_ALV_EVENT.          " events type
    DATA : GT_PRINT TYPE SLIS_PRINT_ALV.           " print table
    *******************MULTIPLE SELECT INPUT
    PARAMETERS**********************
    SELECT-OPTIONS : S_VBELN FOR VBAP-VBELN.
    " multiple selection for sales document
    ******************INITIALIZATION**************************************
    INITIALIZATION.
      REPID = SY-REPID.
    *******************START OF
    SELECTION************************************
    START-OF-SELECTION.
      PERFORM POP_VBAP.
      " populating the table with document item data
      PERFORM POP_MARA.
      " populating the table with general material data
      PERFORM FIELD_CAT.
      " mapping the fields for the field catalog
      PERFORM EVENTS.                      " using the events
      PERFORM BLOCK_LIST.
      " displaying the data in blocked list
    *&      Form  field_cat
          text
    -->  p1        text
    <--  p2        text
    FORM FIELD_CAT .
      WA_FIELDCAT-FIELDNAME = 'VBELN'.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-SELTEXT_L = 'SALES DOC'.
      WA_FIELDCAT-COL_POS = 1.
      WA_FIELDCAT-OUTPUTLEN = 10.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-FIELDNAME = 'POSNR'.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-SELTEXT_L = 'DOC ITEM'.
      WA_FIELDCAT-COL_POS = 2.
      WA_FIELDCAT-OUTPUTLEN = 6.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-FIELDNAME = 'ERNAM'.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-SELTEXT_L = 'NAME'.
      WA_FIELDCAT-COL_POS = 3.
      WA_FIELDCAT-OUTPUTLEN = 12.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-FIELDNAME = 'ERDAT'.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-SELTEXT_L = 'DATE'.
      WA_FIELDCAT-COL_POS = 4.
      WA_FIELDCAT-OUTPUTLEN = 8.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-FIELDNAME = 'MATNR'.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-SELTEXT_L = 'MAT NO'.
      WA_FIELDCAT-COL_POS = 5.
      WA_FIELDCAT-OUTPUTLEN = 18.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT1-FIELDNAME = 'MATNR'.
      WA_FIELDCAT1-TABNAME = 'IT_MARA'.
      WA_FIELDCAT1-SELTEXT_L = 'MAT NO'.
      WA_FIELDCAT1-COL_POS = 1.
      WA_FIELDCAT1-OUTPUTLEN = 18.
      APPEND WA_FIELDCAT1 TO IT_FIELDCAT1.
      CLEAR WA_FIELDCAT1.
      WA_FIELDCAT1-FIELDNAME = 'ERNAM'.
      WA_FIELDCAT1-TABNAME = 'IT_MARA'.
      WA_FIELDCAT1-SELTEXT_L = 'NAME'.
      WA_FIELDCAT1-COL_POS = 2.
      WA_FIELDCAT1-OUTPUTLEN = 12.
      APPEND WA_FIELDCAT1 TO IT_FIELDCAT1.
      CLEAR WA_FIELDCAT1.
      WA_FIELDCAT1-FIELDNAME = 'MATKL'.
      WA_FIELDCAT1-TABNAME = 'IT_MARA'.
      WA_FIELDCAT1-SELTEXT_L = 'MAT DESC'.
      WA_FIELDCAT1-COL_POS = 3.
      WA_FIELDCAT1-OUTPUTLEN = 9.
      APPEND WA_FIELDCAT1 TO IT_FIELDCAT1.
      CLEAR WA_FIELDCAT1.
      WA_FIELDCAT1-FIELDNAME = 'MEINS'.
      WA_FIELDCAT1-TABNAME = 'IT_MARA'.
      WA_FIELDCAT1-SELTEXT_L = 'UNITS'.
      WA_FIELDCAT1-COL_POS = 4.
      WA_FIELDCAT1-OUTPUTLEN = 3.
      APPEND WA_FIELDCAT1 TO IT_FIELDCAT1.
      CLEAR WA_FIELDCAT1.
      WA_FIELDCAT1-FIELDNAME = 'PSTAT'.
      WA_FIELDCAT1-TABNAME = 'IT_MARA'.
      WA_FIELDCAT1-SELTEXT_L = 'STATUS'.
      WA_FIELDCAT1-COL_POS = 5.
      WA_FIELDCAT1-OUTPUTLEN = 15.
      APPEND WA_FIELDCAT1 TO IT_FIELDCAT1.
      CLEAR WA_FIELDCAT1.
    ENDFORM.                    " field_cat
    *&      Form  events
          text
    -->  p1        text
    <--  p2        text
    FORM EVENTS .
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_END_OF_PAGE.
      XS_EVENT-FORM = 'XEND_OF_PAGE'.
      APPEND XS_EVENT TO GT_XEVENTS.
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_TOP_OF_PAGE.
      XS_EVENT-FORM = 'XTOP_OF_PAGE'.
      APPEND XS_EVENT TO GT_XEVENTS.
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_TOP_OF_LIST.
      XS_EVENT-FORM = 'XTOP_OF_LIST'.
      APPEND XS_EVENT TO GT_XEVENTS.
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_END_OF_LIST.
      XS_EVENT-FORM = 'XEND_OF_LIST'.
      APPEND XS_EVENT TO GT_XEVENTS.
      CLEAR XS_EVENT.
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_END_OF_PAGE.
      XS_EVENT-FORM = 'YEND_OF_PAGE'.
      APPEND XS_EVENT TO GT_YEVENTS.
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_TOP_OF_PAGE.
      XS_EVENT-FORM = 'YTOP_OF_PAGE'.
      APPEND XS_EVENT TO GT_YEVENTS.
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_TOP_OF_LIST.
      XS_EVENT-FORM = 'YTOP_OF_LIST'.
      APPEND XS_EVENT TO GT_YEVENTS.
      CLEAR XS_EVENT.
      XS_EVENT-NAME = SLIS_EV_END_OF_LIST.
      XS_EVENT-FORM = 'YEND_OF_LIST'.
      APPEND XS_EVENT TO GT_YEVENTS.
    ENDFORM.                    " events
    *&      Form  XTOP_OF_PAGE
          text
    FORM XTOP_OF_PAGE.
    BREAK-POINT.
      WRITE: / 'X_TOP_OF_PAGE'.
    ENDFORM.                    "XTOP_OF_PAGE
          FORM XTOP_OF_LIST                                             *
    FORM XTOP_OF_LIST.
    BREAK-POINT.
      WRITE: / 'X_TOP_OF_LIST'.
    ENDFORM.                    "XTOP_OF_LIST
          FORM XEND_OF_PAGE                                             *
    FORM XEND_OF_PAGE.
    BREAK-POINT.
      WRITE: / 'X_END_OF_PAGE'.
    ENDFORM.                    "XEND_OF_PAGE
          FORM XEND_OF_LIST                                             *
    FORM XEND_OF_LIST.
    BREAK-POINT.
      WRITE: / 'X_END_OF_LIST'.
    ENDFORM.                    "XEND_OF_LIST
    FORM YTOP_OF_PAGE.
    BREAK-POINT.
      WRITE: / 'Y_TOP_OF_PAGE'.
    ENDFORM.                    "YTOP_OF_PAGE
          FORM YTOP_OF_LIST                                             *
    FORM YTOP_OF_LIST.
    BREAK-POINT.
      WRITE: / 'Y_TOP_OF_LIST'.
    ENDFORM.                    "YTOP_OF_LIST
          FORM YEND_OF_PAGE                                             *
    FORM YEND_OF_PAGE.
    BREAK-POINT.
      WRITE: / 'Y_END_OF_PAGE'.
    ENDFORM.                    "YEND_OF_PAGE
          FORM YEND_OF_LIST                                             *
    FORM YEND_OF_LIST.
    BREAK-POINT.
      WRITE: / 'Y_END_OF_LIST'.
    ENDFORM.                    "YEND_OF_LIST
    *&      Form  POP_VBAP
          text
    -->  p1        text
    <--  p2        text
    FORM POP_VBAP .
      SELECT VBELN
               POSNR
               ERNAM
               ERDAT
               MATNR
               FROM VBAP
               INTO CORRESPONDING FIELDS OF TABLE IT_VBAP
               WHERE VBELN IN S_VBELN.
    ENDFORM.                    " POP_VBAP
    *&      Form  POP_MARA
          text
    -->  p1        text
    <--  p2        text
    FORM POP_MARA .
      LOOP AT IT_VBAP.
        SELECT SINGLE MATNR
                      ERNAM
                      MATKL
                      MEINS
                      PSTAT
                      FROM MARA
                      INTO CORRESPONDING FIELDS OF IT_MARA
                      WHERE MATNR = IT_VBAP-MATNR.
        APPEND IT_MARA.
      ENDLOOP.
    ENDFORM.                    " POP_MARA
    *&      Form  BLOCK_LIST
          text
    -->  p1        text
    <--  p2        text
    FORM BLOCK_LIST .
      CALL FUNCTION 'REUSE_ALV_BLOCK_LIST_INIT'
        EXPORTING
          I_CALLBACK_PROGRAM       = REPID
          I_CALLBACK_PF_STATUS_SET = ' '
          I_CALLBACK_USER_COMMAND  = 'user_command'.
      CALL FUNCTION 'REUSE_ALV_BLOCK_LIST_APPEND'
          EXPORTING
            IS_LAYOUT                        = WA_LAYOUT
            IT_FIELDCAT                      = IT_FIELDCAT
            I_TABNAME                        = 'IT_VBAP'
            IT_EVENTS                        = GT_XEVENTS
      IT_SORT                          =
      I_TEXT                           = ' '
          TABLES
            T_OUTTAB                         = IT_VBAP
    EXCEPTIONS
      PROGRAM_ERROR                    = 1
      MAXIMUM_OF_APPENDS_REACHED       = 2
      OTHERS                           = 3
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      CALL FUNCTION 'REUSE_ALV_BLOCK_LIST_APPEND'
        EXPORTING
          IS_LAYOUT                        = WA_LAYOUT
          IT_FIELDCAT                      = IT_FIELDCAT1
          I_TABNAME                        = 'IT_MARA'
          IT_EVENTS                        = GT_YEVENTS
        IT_SORT                          =
        I_TEXT                           = ' '
        TABLES
          T_OUTTAB                         = IT_MARA
      EXCEPTIONS
        PROGRAM_ERROR                    = 1
        MAXIMUM_OF_APPENDS_REACHED       = 2
        OTHERS                           = 3
      IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      CALL FUNCTION 'REUSE_ALV_BLOCK_LIST_DISPLAY'
       EXPORTING
      I_INTERFACE_CHECK             = ' '
         IS_PRINT                      = GT_PRINT
      I_SCREEN_START_COLUMN         = 0
      I_SCREEN_START_LINE           = 0
      I_SCREEN_END_COLUMN           = 0
      I_SCREEN_END_LINE             = 0
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER       =
      ES_EXIT_CAUSED_BY_USER        =
    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.                    " BLOCK_LIST
    Regards
    vasu

  • End of page in ALV reports

    Hi,
          I am working on alv reports. I am unable work on end of page in this reports. Please if any body can help me out from this situation.
    Thanks & Regards,
    Praveen

    Hi,
    Perform following steps if you are using ALV FM.
    1. Build the events table
    DATA: LS_EVENT TYPE SLIS_ALV_EVENT.
      CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
        EXPORTING
          I_LIST_TYPE = 0
        IMPORTING
          ET_EVENTS   = RT_EVENTS.
      IF SY-SUBRC <> 0.
      ENDIF.
      READ TABLE RT_EVENTS WITH KEY NAME = SLIS_EV_END_OF_PAGE
                               INTO LS_EVENT.
      IF SY-SUBRC = 0.
        MOVE ALV_TOP_OF_PAGE TO LS_EVENT-FORM.
        APPEND LS_EVENT TO RT_EVENTS.
      ENDIF.
    2. Write a subroutine END_OF_PAGE
    FORM END_OF_PAGE.                            "#EC CALLED
      CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
        EXPORTING
          I_LOGO             = SPACE
          IT_LIST_COMMENTARY = ALV_LIST_TOP_OF_PAGE.
      IF SY-SUBRC NE 0.
      ENDIF.
    ENDFORM. 
    3. Build the comments you want to write at the End of Page.
    4. Now call the ALV FM
    CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
        EXPORTING
          I_CALLBACK_PROGRAM = SY-REPID
          IS_LAYOUT          = ALV_LAYOUT
          IT_FIELDCAT        = ALV_FCAT[]
          I_SAVE             = 'X'
          IT_EVENTS          = ALV_EVENTS[]
        TABLES
          T_OUTTAB           = ITAB1
        EXCEPTIONS
          PROGRAM_ERROR      = 0
          OTHERS             = 0.
    Hope it helps.
    Regards,
    Shashank

  • How to print SUM & COUNT at the end of the XML template

    Hello,
    I am generating a payment file in oracle Payments and at the end of the file, I would also like to add a trailer record with sum of the payments and number of payments. Can anyone have any suggestions on having a trailer record with SUM & COUNT.
    Thanks,

    You can use,
    COUNT and SUM of the column to get those values.
    In extext, add a new record and add these function on columns.

  • How to print blank records after the detail records in a masterdetail report

    Hi,
    Developing a report for time and attendance record. In this report I am printing all the employees in a department, limiting the no. of records per page to 10.
    I need to insert blank lines at the end of all of the detail records in a page that has less than 10 employee records so that the no. of records displayed on a page can always be 10(these blank lines will facilitate the management to note down the temporary employees who worked for the department but are not part of the department).
    I am using a tabular form with group above layout.
    The report layout is as follows:
    Department : FINANCE & ADMINISTRATION
    Employee Name | Employee Number |
    1 Jim | 1234 | _________________
    2 John | 5678 |__________________
    3 blank
    4 blank
    5
    6
    7
    8
    9
    10 balnk
    Supervisor's Sign:______________________
    Note: the no. of blank lines should be inserted dynamically based on the no. of emp. records being printed on the page.
    Any help is greatly appreciated.
    Thanks in advance.
    Kavita.

    Your solution works when I am not limiting the no. of records per page for a department to 10 records and when I want to print blanks lines for the depts that has fewer than 10 employees in it.
    Exactly in my report I have several dept's that has more than 10 emp's. In such cases I'll be printing first 10 in one page and the rest in the next page. Now I want to dynamically print the blank lines in the second page depending on the no. of emp's on that page. I tried to acheive this by using a CS column that reset's at page level but, REPORTS is not letting me use CS column that reset's at page level in a format trigger. I also tried to copy the CS value into a parameter and or to a Place holder column and did not help.
    Any more work around ideas to acheive this?? please help.
    Thanks alot
    Kavita.
    Hi
    Create a column called Serial_No in ur emloyee query like this
    select 1 , empno ,ename from emp;
    Create a summary column on the serial column with the function SUM
    and resetting it to Page
    Display the column in the report by using the text color as white
    so it doesn't display in the report
    I think this should help u i believe
    Sri
    Hi,
    Developing a report for time and attendance record. In this report I am printing all the employees in a department, limiting the no. of records per page to 10.
    I need to insert blank lines at the end of all of the detail records in a page that has less than 10 employee records so that the no. of records displayed on a page can always be 10(these blank lines will facilitate the management to note down the temporary employees who worked for the department but are not part of the department).
    I am using a tabular form with group above layout.
    The report layout is as follows:
    Department : FINANCE & ADMINISTRATION
    Employee Name | Employee Number |
    1 Jim | 1234 | _________________
    2 John | 5678 |__________________
    3 blank
    4 blank
    5
    6
    7
    8
    9
    10 balnk
    Supervisor's Sign:______________________
    Note: the no. of blank lines should be inserted dynamically based on the no. of emp. records being printed on the page.
    Any help is greatly appreciated.
    Thanks in advance.
    Kavita.

  • Deleting Zeros at the end of fields in ALV report

    I want to make an ALV report that include both integer and decimals in same column.
    for example :
    1 - 1234.0000
    2 - 0.0027
    i dont want to see zeros at the end of value. 
    But the type will be decimal and integer values will be shown with zeros at the end.
    For Ex.
    I want to take report like this ;
    1 - 1234
    2 - 0.0027
    How can i make this?
    Thanks.
    Edited by: aydnbk on May 14, 2010 3:22 PM

    Hello aydnbk.
    As far as i know, there is no way to do what you want using standard ALV-Functions. There is a field 'DECIMALS' in structure LVC_S_FCAT, but using this field you could only define ONE setting, that would affect ANY value.
    Furthermore i am asking myself, if this feature is really sensible - when numbers are right-justified, a global setting for the number of decimals makes it much easier to compare the values - at least this is my personal opinion...
    If i had to do this trick, i would simply add some character fields to the output-structure and write the values to the charater-fields to enforce this quite special layout.
    Additionally i would set the fields 'NO_OUT' and 'TECH' for the fields of type 'P', that are holding the values - 'NO_OUT' hides the column and 'TECH' ensures, that the field can not be selected in a user-defined layout.
    Hope this helps.
    Regards, Jörg

  • Runtime Error while Displaying End of Page in ALV

    Hi,
    This is the Code i have written.. The top of page is printing when i comment the end of page in the program (BOLD FORMAT)..But when Uncomment the End of page Code this is going to Short dump..and the Runtime Error is..
    A PERFORM was used to call the routine "END_OF_LIST" of the program "ZPROGRAM
    This routine contains exactly 0 formal parameters, but the current
    call contains 1 actual parameters.
    *&      Form  DISPLAY_ALV_VBAP
    FORM DISPLAY_ALV_VBAP .
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          I_CALLBACK_PROGRAM          = V_REPID
          I_CALLBACK_TOP_OF_PAGE      = 'TOP_OF_PAGE1'
          I_CALLBACK_HTML_END_OF_LIST = 'END_OF_LIST'
          I_GRID_TITLE                = 'THIS IS LAST'
          IS_LAYOUT                   = WA_LAYO
          IT_FIELDCAT                 = I_FIELDCAT
        TABLES
          T_OUTTAB                    = IT_VBAP
        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_VBAP
    *&      Form  top_of_page1
          text
    FORM TOP_OF_PAGE1.
      DATA:IT_LISTHEAD2 TYPE SLIS_T_LISTHEADER.
      DATA:WA_LISTHEAD2 TYPE SLIS_LISTHEADER.
      WA_LISTHEAD2-TYP = 'H'.
      WA_LISTHEAD2-INFO = 'THIS IS TOP OF PAGE FOR SECOND LIST'.
      APPEND WA_LISTHEAD2 TO IT_LISTHEAD2.
      CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
        EXPORTING
          IT_LIST_COMMENTARY = IT_LISTHEAD2
          I_LOGO             = 'ENJOYSAP_LOGO'.
    ENDFORM.                    "top_of_page1
    *&      Form  end_of_list
          text
    FORM END_OF_LIST.
      DATA:IT_LISTHEAD1 TYPE SLIS_T_LISTHEADER.
      DATA:WA_LISTHEAD1 TYPE SLIS_LISTHEADER.
      WA_LISTHEAD1-TYP = 'H'.
      WA_LISTHEAD1-INFO = 'THIS IS END OF PAGE FOR SECOND LIST'.
      APPEND WA_LISTHEAD1 TO IT_LISTHEAD1.
    CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
      EXPORTING
       IT_LIST_COMMENTARY       = IT_LISTHEAD1
       I_LOGO                   = 'ENJOYSAP_LOGO'
       I_END_OF_LIST_GRID       = 'X'
    ENDFORM.

    Hi
    The "END_OF_LIST" event is not called as you have called it.
    First capture END_OF_LIST as an event in your events table.
    Then use it.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
    I_CALLBACK_PROGRAM = V_REPID
    I_CALLBACK_TOP_OF_PAGE = 'TOP_OF_PAGE1'
    I_CALLBACK_HTML_END_OF_LIST = 'END_OF_LIST'  <----- Wrong
    I_GRID_TITLE = 'THIS IS LAST'
    IS_LAYOUT = WA_LAYO
    IT_FIELDCAT = I_FIELDCAT
    TABLES
    T_OUTTAB = IT_VBAP
    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_VBAP
    Build an events table like this :
    FORM build_events.
      DATA: ls_event TYPE slis_alv_event.
      CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
        EXPORTING
          i_list_type     = 0
        IMPORTING
          et_events       = gt_events[]
        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 gt_events WITH KEY name =  slis_ev_end_of_page
                  INTO ls_event.
      IF sy-subrc = 0.
        MOVE 'END_OF_PAGE' TO ls_event-form.
        APPEND ls_event TO gt_events.
      ENDIF.
      READ TABLE gt_events WITH KEY name =  slis_ev_end_of_list
                  INTO ls_event.
      IF sy-subrc = 0.
        MOVE 'END_OF_LIST' TO ls_event-form.
        APPEND ls_event TO gt_events.
      ENDIF.
    ENDFORM.                
    And then use the END_OF_list form as you have defined.
    Hope that helps.
    Cheers
    Ravish

  • END OF PAGE IN ALV LIST

    Hi All,
    I am generating the report output in ALV list and downloading in the PDF format. It is working fine.
    But I am not able to print last line(AS SOME TEXT) on each page of the report. I think the output of report in ALV LIST does not show the END OF PAGE, But It should show once we take print out.
    Please let me know.
    Waiting for reply.
    Thanks,
    Rakesh Singh

    Rakesh,
    END OF PAGE can be found in ALV Printout, you can't see it in Display. So if you download as PDF without printing, it is normal not to display END-OF-PAGE.
    You can print your report and you can see the END-OF-PAGE in spool and maybe you can convert this spool as PDF. Otherwise you won't use END-OF-PAGE.
    Look at these links, same topic:
    End of page in ALV reports
    ALV - END_OF_PAGE event
    http://help.sap.com/saphelp_webas630/helpdata/en/ee/c8e071d52611d2b468006094192fe3/content.htm
    End of Page event not triggering in ALV report

  • I find I am unable to print any photo because the program "Can't find a theme and the Print command wont work without at least one theme. How can I overcome this problem?

    I find I am unable to print any photo because the program "Can't find a theme and the Print command wont work without at least one theme. How can I overcome this problem?

    reinstall iPhoto
    see this discussion down a few from your post
    https://discussions.apple.com/thread/5426566?tstart=0
    LN

  • How to print a field on the last page of Smartform with more  of 2 pages?

    HI FRIENDS,
    I NEED TO PRINT ONLY ONE FIELD IN LAST PAGE OF FORM SMARTFORM
    HOW DO I CHECK last page. I tried WITH THE FIELDS OF TABLE
    SFSY BUT NOT worked.      
    The form has  more of  2 pages.
    Thank you.
    ROGERIO VAZ

    Hi ,
    You dont have to hard code anything to achieve this functionality,
    just create a window and in that window define a text element to print
    that variable.In the conditions tab of that window check the check box
    "only after end of main window".i think you might have used a main window,
    so irrespective of the no of pages the smartform prints,it always displays that
    field in the last page of the smartform.
    regards,
    srikanth.

  • How to specify a variable in the path prefix of an External HTTP (RFC) connection (in transaction SM59)

    Hi There,
    Please can someone tell me how to specify a variable in the  path prefix of an External HTTP (RFC) connection in transaction SM59?
    For example if my path prefix is /invoke/test/example?input=XYZ; how do I replace "XYZ" with a variable so that I can pass in any value after "=" ?
    Thanks,
    Brendon

    Hi,
    This is SAP Business one system administration forum. Please find correct forum and repost above discussion to get quick assistance.
    Please close this thread here with helpful answer.
    Thanks & Regards,
    Nagarajan

  • How do I justify text at the end of a column

    How do I justify text at the end of a column In Pages?
    Also, is there any way to sort a document (alphabetically by the first word of each paragraph) that is not in a table?

    RTPLaw writes:
    How do I justify text at
    the end of a column In
    P    a    g    e    s     ?
    Also, is there any way
    to   sort  a  document
    (alphabetically by the
    first   word   of   each
    paragraph) that is not
    in         a         table?
    No. Like Peter and Walt, I wonder why you'd want to, considering the appearance of such manipulation, illustrated above. Is this a requirement for some specific type of document?
    Regarding your second question, there's no way to do this using Pages as it comes out-of-the-box (or in the downloaded edition). But you can sort the paragraphs of a document alphabetically using WordService, freeware from Devon Technologies. The link will take you to their download page. Scroll down to the Freeware section and the download link for WordService.
    Regards,
    Barry

  • How to use bind variables in the following query

    CREATE OR REPLACE PROCEDURE MMDB.test IS
    sel_qtn VARCHAR2 (10);
    CURSOR PT_QUANTITY IS select * from mmdb.product_tree WHERE QUANTITY_CHECK ='E'
    AND run_id = 100
    a PT_QUANTITY%ROWTYPE;
    BEGIN
    FOR i IN PT_QUANTITY
    loop
    sel_qtn := i.quanttity-1;
    While sel_qtn>=1
    loop
    insert into mmdb.product_tree (BILLING_ACCOUNT_NO ,S_CODE) values (i.BILLING_ACCOUNT_NO ,i.S_CODE||'E');
    sel_qtn :=sel_qtn -1;
    End loop;
    commit;
    end;

    Don't duplicate threads: How to use bind variables in the following query

  • How to print Integrity sql in the preparedstatement?

    How to print Integrity sql in the preparedstatement?
    Connection conn = null;
    String sql = "select * from person where name=?";
    PreparedStatement ps = conn.prepareStatement(sql);
    ps.setObject(1, "robin");
    ps.executeQuery();
    i'm wants print Integrity sql.
    For example:select * from person where name='robin'
    How should I do?
    thanks a lot!

    PreparedStatement doesn't offer methods for that. You can write your own implementation of PreparedStatement which wraps the originating PreparedStatement and saves the set* values and writes it to the toString().
    If needed, myself I just print the sql as well as the values-being-set to the debug statement.Logger.debug(query + " " + values);

Maybe you are looking for

  • Want to upgrade to BT Infinity

    Hi, I called BT just now and Infinity is available in my area. But before I upgrade, I have a few questions. I am currently on BT broadband option 3 and the main wired connection (the hub to computer) is in the living room and I have a few other devi

  • Doubt about RFC Destination in FILE to IDOC Async scenario

    hi In FILE-XI-IDOC Async Scenario we are creating RFC Destination in R/3 and XI. For Asyn we don't want response But We are Creating RFC Destination in R/3 also. Any specific reason. Thanks in advance.

  • ABAP runtime error in TSV_ILLEGAL_REFERENCE "Internal Table Destroyed"

    Hi Experts, I am getting an error in Transaction CV01N. In Function Group CTMS, there is a statement REFRESH CONTROL  tab_con FROM SCREEN nnnn. In data decleration tab_con is decalred as : Controls: tab_con TYPE TABLEVIEW  screen nnnn. I am getting s

  • How to execute an ABAP Mapping after a Java Mapping

    Hi, i have found a Bug in XI and SAP said to me that the only solution is to execute an ABAP mapping after my java mapping. I have an IDOC to FILE scenario Could anyone orient me on what do i have to configure, so after my java mapping i can execute

  • How to enable package verificati​on

    how to enable package verification, it is required for one application to be compliance with security policy