Calling script from ALV report

there is button in my report(print) when click on this it needs to display the report output in a script (which is designed for this)
Please help me how to declare my itab variables in Script....
only the data and page number will change rest all text elments are constant for differnet pages.
the code in the USER_COMMAND of reuse_GRID_DISPLAY is
    WHEN 'PRINT'.
      i_itcpo-tdimmed = 'X'.
      i_itcpo-tddelete = 'X'.
      CALL FUNCTION 'START_FORM'
       EXPORTING
  ARCHIVE_INDEX          =
         form                   = 'ZSCRIPT'
         language               = 'SY-LANGU'
         startpage              = 'FIRST'
       EXCEPTIONS
        form                    = 1
         format                 = 2
    unended                = 3
    unopened               = 4
         unused                 = 5
         spool_error            = 6
         OTHERS                 = 7.
       CALL FUNCTION 'OPEN_FORM'
    EXPORTING
                application = 'TX'
               device      = 'PRINTER'
                dialog      = 'X'
                form        = 'ZSCRIPT'
             options     = i_itcpo
           language    = sy-langu.
       PERFORM print_data.
      CALL FUNCTION 'CLOSE_FORM'.
      MESSAGE s208(00) WITH ' Form Successfully Printed.'.
      CALL FUNCTION 'END_FORM'.
THE PERFORM DETAILS................
*Left logo
  CALL FUNCTION 'WRITE_FORM'
       EXPORTING
            element = 'LLOGO'
       EXCEPTIONS
            OTHERS  = 1.
*script header
  CALL FUNCTION 'WRITE_FORM'
       EXPORTING
            element = 'HEADER'
       EXCEPTIONS
            OTHERS  = 1.
*standard text
  CALL FUNCTION 'WRITE_FORM'
       EXPORTING
            element = 'TEXT'
       EXCEPTIONS
            OTHERS  = 1.
*dispos detials
  CALL FUNCTION 'WRITE_FORM'
       EXPORTING
            element = 'DISPOSI'
       EXCEPTIONS
            OTHERS  = 1.
*ECN number
  CALL FUNCTION 'WRITE_FORM'
       EXPORTING
            element = 'ECN'
       EXCEPTIONS
            OTHERS  = 1.
*out_tab headings and data
  LOOP AT it_rep_out INTO wa_rep_out.
    CALL FUNCTION 'WRITE_FORM'
         EXPORTING
              element = 'DETAIL_A'
         EXCEPTIONS
     OTHERS  = 1.
    CALL FUNCTION 'WRITE_FORM'
         EXPORTING
              element = 'MAIN'
         EXCEPTIONS
              element = 1
              window  = 2.
    IF sy-subrc NE 0.
    ENDIF.
  ENDLOOP.
*Comments from selection screen
  CALL FUNCTION 'WRITE_FORM'
       EXPORTING
           element = 'FOOTER'
       EXCEPTIONS
            OTHERS  = 1.

Hi,
first store all the relevant data in internal table itab.
loop at itab.
call write form
endloop.
care should be taken that you write the itab in main window.
in script just add
&itab-var1& &itab-var2& and so on...
Regards,
sumit

Similar Messages

  • Call tcode from alv report and passing  group of values

    hi all .
    i want to call tcode from alv report and passing an internal table or group of values to a selection option of that t code ? how
    ex. passing group of GL to fbl3n and display the detials of all .
    thank you

    Dear,
    You have done a small mistake
    --> rspar_line-option = 'EQ'.
         rspar_line-HIGH = PDATE-HIGH.
    u r passing "high" value and in "option u r passing "EQ" so how it will work!!!
    So if u r passing only 1 date or more dates like 01.01.2010 , 15.02.2010 , 10.03.2010 then pass
    rspar_line-selname = 'SO_BUDAT'.
    rspar_line-kind = 'S'.
    rspar_line-sign = 'I'.
    rspar_line-option = 'EQ'.
    rspar_line-LOW = PDATE-HIGH.
    APPEND rspar_line TO rspar_tab.
    or if u r passing low & high date means in range like 01.01.2010 to 30.01.2010, then pass
    rspar_line-selname = 'SO_BUDAT'.
    rspar_line-kind = 'S'.
    rspar_line-sign = 'I'.
    rspar_line-option = 'BT''.
    rspar_line-LOW = PDATE-LOW.
    rspar_line-HIGH = PDATE-HIGH.
    APPEND rspar_line TO rspar_tab.
    try above code , hope it helps...
    i think u cannot use "call transaction using bdcdata" in ur case bcoz as u said in ur 1st post u want to display the details of all but still if u want to use then u should pass all parameters in  loop.
    PROGRAM
    DYNPRO
    DYNBEGIN
    FNAM
    FVAL
    ex:-
    LOOP AT GT_TEMP INTO GS_TEMP.
    CLEAR bdcdata_wa.
    bdcdata_PROGRAM = 'SAPXXXX'.
    bdcdata_DYNPRO = '1000'.
    bdcdata_DYNBEGIN = 'X'.
    bdcdata_wa-fnam = '''.
    bdcdata_wa-fval = ''.
    APPEND bdcdata_wa TO bdcdata_tab.
    CLEAR bdcdata_wa.
    bdcdata_PROGRAM = ''.
    bdcdata_DYNPRO = ''.
    bdcdata_DYNBEGIN = ''.
    bdcdata_wa-fnam = 'SD_SAKNR'.
    bdcdata_wa-fval = GS_TEMP-GLACCOUNT.
    APPEND bdcdata_wa TO bdcdata_tab.
    CLEAR bdcdata_wa.
    bdcdata_PROGRAM = ''.
    bdcdata_DYNPRO = ''.
    bdcdata_DYNBEGIN = ''.
    bdcdata_wa-fnam = 'BDC_OKCODE'.
    bdcdata_wa-fval = 'XXX'.
    APPEND bdcdata_wa TO bdcdata_tab.
    ENDLOOP.
    try above code if u r using call transaction...
    Edited by: mihir6666 on Jul 9, 2011 3:10 PM
    Edited by: mihir6666 on Jul 9, 2011 3:11 PM
    Edited by: mihir6666 on Jul 9, 2011 3:13 PM

  • Can we call screen from ALV report

    Hi All,
    I am in the process of creating a stand alone application. However I have stuck up here.
    Problem: Can we call any screen from ALV report? If yes then how??? Can anyone give some code snippet??
    All your help appreciated.
    Thanks,
    Jignesh

    Hello Jignesh,
    Here is an example, when you double click on a line, it pops with with another screen that holds details for the flight information.
    CLASS lcl_event_handler DEFINITION.
      PUBLIC SECTION.
        METHODS:
        handle_double_click FOR EVENT double_click
                            OF cl_gui_alv_grid
                            IMPORTING e_row
                                      e_column.
       ENDCLASS.                    "lcl_event_handler
    CLASS lcl_event_handler IMPLEMENTATION.
      METHOD handle_double_click.
        READ TABLE it_flight INTO wa_flight INDEX e_row-index.
        IF sy-subrc EQ 0.
          SELECT * FROM sbook
                   INTO TABLE it_book
                   WHERE carrid EQ wa_flight-carrid AND
                         connid EQ wa_flight-connid.
          CALL SCREEN 101 STARTING AT 10 10.
        ENDIF.
      ENDMETHOD.                 "HANDLE_DOUBLE_CLICK
    ENDCLASS.                    "LCL_EVENT_HANDLER
    MODULE status_0101 OUTPUT.
    Variant to save the layout
      gv_repid = sy-repid.
      IF g_custom_container2 IS INITIAL.
    Create an instance for Custom Container 'ALV_GRID'
        CREATE OBJECT g_custom_container2
               EXPORTING container_name = gs_container2.
    Create an instance for ALV Grid
        CREATE OBJECT g_grid2
               EXPORTING i_parent = g_custom_container2.
    Variant to save the layout
        gs_layout-grid_title = 'Flight Bookings'.
        CALL METHOD g_grid2->set_table_for_first_display
          EXPORTING
            i_structure_name = 'SBOOK'
            is_layout        = gs_layout
          CHANGING
            it_outtab        = it_book[].
      ELSE.
        CALL METHOD g_grid2->refresh_table_display.
      ENDIF.                               "IF grid2 IS INITIAL.
    Setting focus for created grid control
      CALL METHOD cl_gui_control=>set_focus
        EXPORTING
          control = g_grid2.
      CALL METHOD cl_gui_cfw=>flush.
    ENDMODULE.                 " status_0101  OUTPUT
    Refer to BC_ALV_GRID04 for ALV data declarations used in the above piece of code.

  • Excel fiel from ALV report

    Hi Gurus,
        is der any way to download data from ALV report to excel sheet depending on  layout set dyanmically.
      I mean to say that if I choose a layout then data has to transfer to excel sheet according to layout fields automaticaly.

    I think this can be done by oops ALV , are u using reusealv F.M to call output in ALV ?
    Try the below kind of ALV
    IN PBO -
    >
    SET PF-STATUS 'PROJREP'.
    SET TITLEBAR text-046.
    DATA: g_container TYPE scrfname VALUE 'ALV',
          g_grid1  TYPE REF TO cl_gui_alv_grid,
          g_custom_container TYPE REF TO cl_gui_custom_container.
    IF g_custom_container IS INITIAL.
        CREATE OBJECT g_custom_container
               EXPORTING container_name = g_container.  (Name of the container )
    CREATE OBJECT g_grid1
               EXPORTING i_parent = g_custom_container.
    PERFORM create_field_catalog_ce
    CALL METHOD g_grid1->set_frontend_fieldcatalog
          EXPORTING
            it_fieldcatalog = t_fcat_ce.
    ALL METHOD g_grid1->set_table_for_first_display
          EXPORTING
            i_structure_name = 'ST_DISPLAY'
          CHANGING
            it_outtab        = t_display_io
            it_fieldcatalog  = t_fcat_ce.
    ->Create Object to receive events and link them to handler methods.
    When the ALV Control raises the event for the specified instance
    the corresponding method is automatically called.
        CREATE OBJECT g_event_receiver.
        SET HANDLER g_event_receiver->handle_double_click FOR g_grid1.
      ENDIF.
      CALL METHOD cl_gui_control=>set_focus
        EXPORTING
          control = g_grid1.
    IN PAI -->
    CALL METHOD cl_gui_cfw=>dispatch.

  • Jump from alv report to qa03 screen based on PRUEFLOS field

    Hi experts,
    I developed one alv report ,in that one field name is PRUEFLOS (inspection lot number).I want to jump from alv report
    to QA03 screen based on PRUEFLOS field.I wrote in this way but i didn't get.
    FORM USER_COMMAND USING UCOMM LIKE SY-UCOMM SELFIELD TYPE SLIS_SELFIELD.
      CASE SELFIELD-FIELDNAME.
        WHEN 'PRUEFLOS'.
          READ TABLE T_FINAL INDEX SELFIELD-TABINDEX.
          SET PARAMETER ID  'QLS' FIELD T_FINAL-PRUEFLOS.
          CALL TRANSACTION 'QA03'   AND SKIP FIRST SCREEN.
      ENDCASE.
    ENDFORM.
    what is the problem ?pls help me in this.

    Hi Ram,
    Recheck:
    1) You have passed 'FORM USER_COMMAND' in 'I_CALLBACK_USER_COMMAND' while calling f.m. for ALV displa, and
    2) You have checked the value of user command, i.e.
    FORM USER_COMMAND USING UCOMM LIKE SY-UCOMM SELFIELD TYPE SLIS_SELFIELD.
    CASE SY-UCOMM.
    WHEN '&IC1'.
    CASE SELFIELD-FIELDNAME.
    WHEN 'PRUEFLOS'.
    READ TABLE T_FINAL INDEX SELFIELD-TABINDEX.
    SET PARAMETER ID 'QLS' FIELD T_FINAL-PRUEFLOS.
    CALL TRANSACTION 'QA03' AND SKIP FIRST SCREEN.
    ENDCASE.
    ENDCASE.
    ENDFORM.
    Regards,
    Birendra

  • Jump from alv report to cor2 screen

    Hi experts,
    I develop one alv report ..i want to jump from alv report to COR2 screen when click on order number(field name is AUFNR).
    i wrote code in this way.
    FORM USER_COMMAND USING UCOMM LIKE SY-UCOMM SELFIELD TYPE SLIS_SELFIELD
      CASE SELFIELD-FIELDNAME.
        WHEN 'AUFNR'.
          READ TABLE T_FINAL INDEX SELFIELD-TABINDEX.
          SET PARAMETER ID  'AUF' FIELD T_FINAL-AUFNR.
          CALL TRANSACTION 'COR2'   AND SKIP FIRST SCREEN.
      ENDCASE.
    ENDFORM.
    but it is not working properly,when u click on any order number it is going only the same order number(in cor2 screen).
    what is the problem? set par id (AUF) EXIST IN TPARA table compulsalory or it is created automatically?
    pls help me in this . If possible pls send the code.

    Hi,
    I have already mentioned both ways, but ok, once again.
    A. how I found parameter ID ANR:
    1.) run transaction COR2
    2.) set cursor to field "Process order"
    3.) press F1 button
    4.) performance assistant displays
    5.) press "Technical Information"
    6.) technical information displays
    7.) in field "Parameter ID" you can see parameter ID assigned to a screen field
    B. how I found parameter ID BR1:
    1.) switch on debugger
    2.) run transaction COR2
    3.) put a breakpoint on "GET PARAMETER" statement
    4.) debugger stops on every GET PARAMETER statement in PBO of COR2
    5.) there you can see that BR1 is used for field AUFNR
    Basically first mentioned way is sufficient, because system gets parameter value from parameter ID assigned to a screen element automatically. But in this case a value is overwritten by coding in PBO of COR2.
    Hope it helps.
    Regrds,
    Adrian

  • Calling an existing ALV report in WD4A

    Im going to try to call an existing ALV report using WD4A.
    Was wondering if anybody has used the "SUBMIT <report> EXPORTING LIST TO MEMORY" option to get the results table, then after IMPORTING from memory, display this in ALV in Webdynpro abap?

    I was able to acomplish the following way...
    My WD4A component has an assistance class, has a method fetch_results, in that method, I pass my selection criteria which calls a function.
    The function does this...
      SUBMIT  REPORTXYZ
      USING SELECTION-SET lv_variant
      AND RETURN
        WITH pnppernr IN pnppernr
        WITH pnpbegps EQ act_begda
        WITH pnpendps EQ act_endda
        WITH pnpbegda EQ act_begda
        WITH pnpendda EQ act_endda
        WITH pnptimed EQ blank
        WITH p_layout EQ '/MGR SEP'
        WITH p_portal EQ 'X'.
    My p_portal parameter is a flag that REPORTXYZ will use to export the it_output to memory.
    I then import that table to the function module which returns to WD4A alv.
      IMPORT zit_output TO tbl_output FROM MEMORY ID
        lv_flag.

  • Exporting data from ALV Report...

    Dear All,
    While I am exporting data from ALV report to any other Format (Excel, Txt, HTML) it only export the data of last column, but the heading is comming properly and also the column heading is displaying properly.
    So how to rectify it. (the report is Object Oriented).
    Regards,
    Dahrmesh

    Hi Davabap,
    Refer this sample program "BCALV_GRID_VERIFY" . I hope it is problem with structure mismatching.
    Otherwise can you paste your code ?
    Regards,
    Vicky
    PS: Award points if helpful

  • Query regarding calling T-code MIGO from ALV report output

    Dear friends,
    I have to call MIGO transaction  from my ALV report output. Now problem is that I have to set the value 'display' In the first header field, 'Material Document' in 2nd header field when MIGO is called from the report output. Morever there is no parameter ID for these two fields. So how to set the values w/o using parameter ids.
    Regards,
    Rishi

    Hi,
    Try this coding,
    FORM DISPLAY.
    CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
    EXPORTING
       I_CALLBACK_PROGRAM             = SY-REPID
       I_CALLBACK_USER_COMMAND        = 'USER_COMMAND'
       IS_LAYOUT                      = AK_LAYOUT
       IT_FIELDCAT                    = AK_FIELDCAT
      TABLES
       T_OUTTAB                       = ITAB.
    ENDFORM.                    " DISPLAY
    *&      Form  EVENT
    FORM EVENT USING P_AK_EVENT TYPE SLIS_T_EVENT.
      DATA : AK_EVENT1 TYPE SLIS_ALV_EVENT.
      AK_EVENT1-NAME = 'USER_COMMAND'.
      AK_EVENT1-FORM = 'USER_COMMAND'.
      APPEND AK_EVENT1 TO P_AK_EVENT.
    ENDFORM.                    " EVENT
    *&      Form  USER_COMMAND
    FORM USER_COMMAND USING R_UCOMM LIKE SY-UCOMM
                            RS_SELFIELD TYPE SLIS_SELFIELD.
      IF R_UCOMM = '&IC1'.
      " AND SY-LSIND = '1'.
        READ TABLE ITAB INDEX RS_SELFIELD-TABINDEX.
        SET PARAMETER ID 'AUN' FIELD ITAB-BUDAT.
        CALL TRANSACTION 'MIGO' AND SKIP FIRST SCREEN.
      ENDIF.
    ENDFORM.                    " USER_COMMAND
    Regards,
    Nikhil.

  • Calling standard printer driver program RVADOR01 from ALV report

    I have ALV report (Sales order documents) and one of columns in report is icon type with print preview link (hotspot). When user press icon, I would like to call standard print program RVADOR01 (actually we have custom Z_RVADOR01 and custom smartform which are working fine when using Document -> Output in VA03) to display print preview. I don't know how to call (trigger) print driver routine and pass needed parameters to it (ex. SO number).
    Marko

    Actually I did that. But then you are at least three clicks away from print preview screen. For testing purpose I've created custom smartform and run it from my report. It is working like I want. Now, instead of my procedure I want to run standard printer driver program with needed parameters. I believe that all it needs is document number (vbeln) and all the rest is already there, program, smatform... I just don't know how to use it (ex. pass parameters).
    I know I maybe complicating too much but I am ABAP beginner and want to learn as much as possible. Thank you anyway!

  • Data missing when Exporting or print preview from ALV report

    Hi
    I have a alv report which is showing fine but when i try to export it to say excel sheet or do print preview some of the data is missing. Can anyone tell me how to fix this. or at least point to some document that discuss this problem.
    Here is my ALV CODE
    *  CALL_ALV
    form call_alv.
    *  v_repid = sy-repid.
      perform build_field_catalog using field_tab[].
      perform build_eventtab      using events[].
      perform comment_build       using header_alv[].
      perform build_sorttab       using gt_sort[].
    *  perform build_layout.
    *  v_variant-variant = '/TEST3'.
    * Call ABAP List Viewer
      call function 'REUSE_ALV_GRID_DISPLAY'
        exporting
          i_callback_program      = v_repid
          i_callback_user_command = ''
          i_structure_name        = 'REC'
          it_fieldcat             = field_tab[]
          it_special_groups       = gt_sp_group[]
          it_sort                 = gt_sort[]
          i_save                  = v_save
          is_variant              = v_variant
          it_events               = events[]
    *      is_layout               = gd_layout
        tables
          t_outtab                 = REC
        exceptions
          program_error            = 1
          others                   = 2.
    endform.
    From my Catalog this data is missing
    * BUILD_FIELD_CATALOG
    form build_field_catalog USING pt_fieldcat type
                                   slis_t_fieldcat_alv.
      data:  ls_fieldcat type slis_fieldcat_alv.
      clear: fieldcat, pt_fieldcat[].
      ls_fieldcat-tabname        =                'REC'.
      ls_fieldcat-edit           =                ' '.
        ls_fieldcat-fieldname      =                'PERNR'.
        ls_fieldcat-seltext_s      =                'Employee #     '.
        ls_fieldcat-seltext_m      =                'Employee #           '.
        ls_fieldcat-seltext_l      =                'Employee #           '.
        ls_fieldcat-datatype       =                'C'.
        append ls_fieldcat to pt_fieldcat.
    There r coupole that's missing
    But there couple that show's up like this one
        ls_fieldcat-fieldname      =                'STIME'.
        ls_fieldcat-seltext_s      =                'ST   '.
        ls_fieldcat-seltext_m      =                'St Tm     '.
        ls_fieldcat-seltext_l      =                'Start Time          '.
        ls_fieldcat-datatype       =                'C'.
        append ls_fieldcat to pt_fieldcat.
        ls_fieldcat-fieldname      =                'ETIME'.
        ls_fieldcat-seltext_s      =                'ET      '.
        ls_fieldcat-seltext_m      =                'Et Tm           '.
        ls_fieldcat-seltext_l      =                'End Time             '.
        append ls_fieldcat to pt_fieldcat.
    I always reward points.
    Thanks

    hi Anwarul,
    Try the following code:
    *  CALL_ALV
    form call_alv.
    *  v_repid = sy-repid.
      perform build_field_catalog using field_tab[].
      perform build_eventtab      using events[].
      perform comment_build       using header_alv[].
      perform build_sorttab       using gt_sort[].
    *  perform build_layout.
    *  v_variant-variant = '/TEST3'.
    * Call ABAP List Viewer
      call function 'REUSE_ALV_GRID_DISPLAY'
        exporting
          i_callback_program      = v_repid
          i_callback_user_command = ''
          i_structure_name        = 'REC'
          it_fieldcat             = field_tab[]
          it_special_groups       = gt_sp_group[]
          it_sort                 = gt_sort[]
          i_save                  = v_save
          is_variant              = v_variant
          it_events               = events[]
    *      is_layout               = gd_layout
        tables
          t_outtab                 = REC
        exceptions
          program_error            = 1
          others                   = 2.
    endform.
    form build_field_catalog USING pt_fieldcat type
                                   slis_t_fieldcat_alv.
    call function 'REUSE_ALV_FIELDCATALOG_MERGE'
    exporting
    I_PROGRAM_NAME  = sy-repid
    I_STRUCTURE_NAME = 'REC'
    changing
    CT_FIELDCAT          = pt_fieldcat.
    When you export to excel, the character fields and numeric columns gets re-arranged, but all the fields will be displayed in this case.
    hope this helps.

  • Print Preview and Export not working FROM ALV Report

    Hi
    I have this ALV report which is working fine. But when I try to do a print preview it doesn't show the columns which r sorted. The columns r there but the data starts from the one which is not sorted so the layout is all messed up. In the ALV report the columns that r sorted groups them into one, I mean they just show only one time rest of the row for the same thing is blank it doesn't repeat the same data in those column. I am not sure whether that's causing it or not.
    Please help.

    Hi Anwarul,
    do not sort passing parameters for sorting. Create a layout (called ALV variant) or do the sorting online clicking columns(s) and sort icons. It will not change when displayed in print preview.
    What function/object do you use?
    Regards,
    Clemens

  • Excel sheet upload from alv report.

    hi friends,
            we created one report which will display about sales from vender,.  we created it as hirarical alv report.  
    we all know when we downloaded the data which is shown on report to excel sheet  standard report will run. but when i saw my excel file most of rows are exported finly but some of rows are clubed into another row colum.  how it is happening. the data is passed to excel sheet  by standard report how this prablem is happening.
    plz guide me
    thanq,
    rajesh.k

    hi
    use code below to upload excel.
    CALL METHOD CL_GUI_FRONTEND_SERVICES=>GUI_UPLOAD
    EXPORTING
       FILENAME                = 'exccel Worksheet.txt'
       FILETYPE                = '.XLS'
       HAS_FIELD_SEPARATOR     = '#'
       HEADER_LENGTH           = 0
       READ_BY_LINE            = 'X'
       DAT_MODE                = SPACE
       CODEPAGE                = SPACE
       IGNORE_CERR             = ABAP_TRUE
        REPLACEMENT             = '#'
       VIRUS_SCAN_PROFILE      =
    IMPORTING
       FILELENGTH              =
       HEADER                  =
    CHANGING
       DATA_TAB                = <fs_dict>
    EXCEPTIONS
       FILE_OPEN_ERROR         = 1
       FILE_READ_ERROR         = 2
       NO_BATCH                = 3
       GUI_REFUSE_FILETRANSFER = 4
       INVALID_TYPE            = 5
       NO_AUTHORITY            = 6
       UNKNOWN_ERROR           = 7
       BAD_DATA_FORMAT         = 8
       HEADER_NOT_ALLOWED      = 9
       SEPARATOR_NOT_ALLOWED   = 10
       HEADER_TOO_LONG         = 11
       UNKNOWN_DP_ERROR        = 12
       ACCESS_DENIED           = 13
       DP_OUT_OF_MEMORY        = 14
       DISK_FULL               = 15
       DP_TIMEOUT              = 16
       NOT_SUPPORTED_BY_GUI    = 17
       ERROR_NO_GUI            = 18
       others                  = 19
    *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 transaction in ALV report

    Dear Experts,
    I want to call transaction HUMO from my ALV report on double click on Handling unit no.
    I want to pass the Handling unit through my report and skip the first screen.
    I try it using Call Transaction but the filed Handling unit doesn't have a parameter ID.
    I also try it using Submit but the program is a function pool.
    Can anyone please help me out in solving the issue.
    Thanks in advance
    Best regards
    Ankur G.

    Hai,
    This can be achieved by creating custom parameter id.
    1.Go to the table maintenance generator of the table TPARA and go to the Maintain button through the transaction SM30. 
    Enter the table view name TPARA.
    2.Click on the maintain button. The following information will appear. Click on the Tick button or the ENTER button to go to the next screen.
    3.Enter the Set/Get parameter id as the parameter ID you want to create. Here, I will be creating the parameter Id as ZNAME_DATA1. Click on ENTER button.
    4.It will ask for the text of the parameter Id. Enter the text of the parameter ID and click on the Save button.
    5.Now go to the SE11 transaction for creating a data element and enter the parameter id at the Further Characteristics tab at the parameter Id section.
    6.Activate the data element and use it with the program. It will act the same good as a standard one.

  • Top of page data is repeated while going back from alv report

    Hi,
       In my alv report , I call ed TOP_OF_PAGE.   Data regatding top_of_page is stored in internal table.
       After executing the report,while going back from report,  a screen containing top_of_page data is appeaing.
       Even though I cleared that table,still that data appeared.
      Please resolve this.

    Hi all,
       I cleared that table previously .
       Still that screen appears.
    This is my following code.
    PERFORM top_of_page.            " Subroutine for Top-of-page
    *Display Report
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
       EXPORTING
            I_INTERFACE_CHECK                 = ' '
            I_BYPASSING_BUFFER                = ' '
            I_BUFFER_ACTIVE                   = ' '
              i_callback_program                = lv_repid
            I_CALLBACK_PF_STATUS_SET          = ' '
            I_CALLBACK_USER_COMMAND           = ' '
              i_callback_top_of_page            = 'TOP_OF_PAGE'
            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                       = lt_fieldcat[]
            IT_EXCLUDING                      =
            IT_SPECIAL_GROUPS                 =
            IT_SORT                           =
            IT_FILTER                         =
            IS_SEL_HIDE                       =
            I_DEFAULT                         = 'X'
            I_SAVE                            = ' '
            IS_VARIANT                        =
            IT_EVENTS                         = it_events
            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
            I_HTML_HEIGHT_TOP                 = 0
            I_HTML_HEIGHT_END                 = 0
            IT_ALV_GRAPHICS                   =
            IT_HYPERLINK                      =
            IT_ADD_FIELDCAT                   =
            IT_EXCEPT_QINFO                   =
            IR_SALV_FULLSCREEN_ADAPTER        =
          IMPORTING
            E_EXIT_CAUSED_BY_CALLER           =
            ES_EXIT_CAUSED_BY_USER            =
       TABLES
              t_outtab                          = lt_meter
       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.
    perform clear_data.
    endif.
    FORM top_of_page .
    Declaration of local variables, structures and internal tables
      Data : lv_count      TYPE i,
             lv_count_c(9) TYPE c,
             lt_header     TYPE slis_t_listheader,
             wa_header     TYPE slis_listheader,
             lt_line       LIKE wa_header-info.
    Title
      clear lt_header[].
      wa_header-typ  = 'H'.
      wa_header-info = 'Meter Readings Report'.
      APPEND wa_header TO lt_header.
      CLEAR wa_header.
    Total No. of Records Selected
      DESCRIBE TABLE lt_meter LINES lv_count.
      lv_count_c      = lv_count.
      CONCATENATE 'Total Number of meters readed for given cycle: ' lv_count_c
         INTO lt_line SEPARATED BY space.
      wa_header-typ    =    'A'.
      wa_header-info   =    lt_line.
      APPEND wa_header TO lt_header.
      CLEAR: wa_header, lt_line.
    *Display Top-of-page
      CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
        EXPORTING
          it_list_commentary = lt_header.
    ENDFORM.                    " TOP_OF_PAGE
    *&      Form  CLEAR_DATA
          text
    -->  p1        text
    <--  p2        text
    form CLEAR_DATA .
    data : lt_header     TYPE slis_t_listheader.
    clear lt_header[].
    endform.

Maybe you are looking for

  • Page numbering in InDesign CS5.5 not working

    21 Chapters have been added to InDesign CS5.5's Book File feature. However, only the individual chapter numbers are shown, not the cumulative numbering system. Can anyone please help resolve this issue.

  • Data Action is converting in to data page with  parameter="unknown"

    Hi, I have created one DataAction, and drag a method from appmoduleImpl on to the created data action. that method contains one parameter as well. Now i want to write code in findForward() method on that action class (from gotoCode menu item). After

  • Hot Code Replace Problem...

    Hi Everyone, I am using WebLogic 10 with Eclipse. Whenever i start the server in debug mode and make two three changes in the code... WHAM.... I get the Hot Code Replace error. Is there any way so that the server can keep up with the code changes. Pu

  • Download service manual for dv7-1243cl

    Where can I download the service manual for a dv7-1243cl I have just been informed that the fan assembly is not an end user replaceable item.  The laptop is out of warranty and I am an experienced tech.  I have been able to download the manual for bo

  • While digitizing camcorder video, PE7 has begun splitting into lots of little video files.  Help!

    I have successfully imported/digitized ca. 80 analog Hi-8 camcorder home videos into PE7 from a Sony Digital Handycam camcorder via a FireWire cable/interface.  However, PE7 has now begun splitting the incoming video feed from the camcorder into lots