Prob with Drill down ALV's Layout

Hi Friends,
I have developed a report with class based ALV grid.
First screen 100 - has an ALV for header details.
  CALL METHOD G_GRID_100->SET_TABLE_FOR_FIRST_DISPLAY
    EXPORTING
      IS_VARIANT           = GS_DISVARIANT
      IS_LAYOUT            = GS_LAYOUT
      IT_TOOLBAR_EXCLUDING = GT_EXCLUDE
      I_SAVE               = 'A'
    CHANGING
      IT_OUTTAB            = GT_DATA
      IT_FIELDCATALOG      = GT_FIELDCAT100.
on double click of any record in primary ALV, another screen 200 is called with line item details of that header in screen 100.
    CALL METHOD G_GRID_200->SET_TABLE_FOR_FIRST_DISPLAY
      EXPORTING
        IS_VARIANT           = GS_DISVARIANT1
        IS_LAYOUT            = GS_LAYOUT1
        IT_TOOLBAR_EXCLUDING = GT_EXCLUDE
        I_SAVE               = 'A'
      CHANGING
        IT_FIELDCATALOG      = GT_FIELDCAT200
        IT_OUTTAB            = GT_LINEITEM.
Problem: what ever layout is set in header alv is being copied in lineitem alv.
I want to have independent layouts for primary and secondary ALVs.
How to do that.
Any help on this is highly appreciated.
Regards,
Simha

it is working for me. here is one working example. some where you are doing a mistake cross check it once.
REPORT  ztest_alv_oo.
DATA: it_carr TYPE TABLE OF scarr,
      it_flight TYPE TABLE OF sflight.
DATA: grid1 TYPE REF TO cl_gui_alv_grid,
      grid2 TYPE REF TO cl_gui_alv_grid,
      con1 TYPE REF TO cl_gui_custom_container,
      con2 TYPE REF TO cl_gui_custom_container.
DATA: layout1 TYPE lvc_s_layo,
      layout2 TYPE  lvc_s_layo.
*       CLASS cl_defintion
CLASS cl_one DEFINITION.
  PUBLIC SECTION.
    METHODS:
        double_click         FOR EVENT double_click
                             OF cl_gui_alv_grid
                             IMPORTING e_row
                                       e_column
                                       es_row_no.
ENDCLASS.                    "cl_defintion
*       CLASS cl_implemenatation
CLASS cl_one IMPLEMENTATION.
  METHOD double_click.
    DATA: wa_carr TYPE scarr.
    READ TABLE it_carr INTO wa_carr INDEX e_row-index.
    IF sy-subrc EQ 0.
      SELECT * FROM sflight
      INTO TABLE it_flight
      WHERE carrid EQ wa_carr-carrid.
      CALL SCREEN 200.
    ENDIF.
  ENDMETHOD.                    "double_click
ENDCLASS.                    "cl_implemenatation
START-OF-SELECTION.
  DATA: obj TYPE REF TO cl_one.
  SELECT * FROM scarr
  INTO TABLE it_carr.
  CALL SCREEN 100.
*&      Module  STATUS_0100  OUTPUT
*       text
MODULE status_0100 OUTPUT.
  SET PF-STATUS 'CARR'.
  IF con1 IS INITIAL.
    CREATE OBJECT con1
      EXPORTING
        container_name = 'CAR'.
    CREATE OBJECT grid1
      EXPORTING
        i_parent = con1.
    layout1-grid_title = 'Carrid data'.
    layout1-smalltitle = 'X'.
    layout1-sel_mode   = 'A'.
    layout1-cwidth_opt = 'X'.
    layout1-zebra      = 'X'.
    grid1->set_table_for_first_display(
      EXPORTING
        i_structure_name              = 'SCARR'
        is_layout                     = layout1
      CHANGING
        it_outtab                     = it_carr
      EXCEPTIONS
        invalid_parameter_combination = 1
        program_error                 = 2
        too_many_lines                = 3
    IF sy-subrc NE  0.
      MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                 WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.
    CREATE OBJECT obj.
    SET HANDLER obj->double_click FOR grid1.
  ENDIF.
ENDMODULE.                 " STATUS_0100  OUTPUT
*&      Module  USER_COMMAND_0100  INPUT
*       text
MODULE user_command_0100 INPUT.
  CASE sy-ucomm.
    WHEN 'BACK' OR 'CANCEL' OR 'EXIT'.
      LEAVE TO SCREEN 0.
  ENDCASE.
ENDMODULE.                 " USER_COMMAND_0100  INPUT
*&      Module  STATUS_0200  OUTPUT
*       text
MODULE status_0200 OUTPUT.
  SET PF-STATUS 'FLIGHT'.
  IF con2 IS INITIAL.
    CREATE OBJECT con2
      EXPORTING
        container_name = 'FLIGHT'.
    CREATE OBJECT grid2
      EXPORTING
        i_parent = con2.
    layout2-grid_title = 'Flights data'.
    layout2-smalltitle = 'X'.
    layout2-sel_mode   = 'A'.
    layout2-cwidth_opt = 'X'.
    layout2-zebra      = 'X'.
    grid2->set_table_for_first_display(
      EXPORTING
        i_structure_name              = 'SFLIGHT'
        is_layout                     = layout2
      CHANGING
        it_outtab                     = it_flight
      EXCEPTIONS
        invalid_parameter_combination = 1
        program_error                 = 2
        too_many_lines                = 3
    IF sy-subrc NE  0.
      MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                 WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.
  ELSE.
    CALL METHOD grid2->refresh_table_display.
  ENDIF.
ENDMODULE.                 " STATUS_0200  OUTPUT
*&      Module  USER_COMMAND_0200  INPUT
*       text
MODULE user_command_0200 INPUT.
  CASE sy-ucomm.
    WHEN 'BACK' OR 'CANCEL' OR 'EXIT'.
      LEAVE TO SCREEN 0.
  ENDCASE.
ENDMODULE.                 " USER_COMMAND_0200  INPUT
Container names are CAR, FLIGHT(for 100, 200 respectively)

Similar Messages

  • Exporting a Report to a pdf file with drill down!

    Hi,
    I would like to export a Report to a pdf file.
    My Report includes drill down options. I require the exported pdf with drill down options.
    (Similar to Navigation options in a PDF file).
    I hope this makes sense.
    Please provide a better solution for me.
    If am not wrong, this facility is not available with Crystal Reports!!!
    Thanks,
    Ramesh.

    Hi Ramesh
    You can download the trial versions of the Crystal Report from the following link:
    https://websmp202.sap-ag.de/support (Please copy the link and paste it to your web browser).
    You can get the license by putting a request in the follwoing link:
    https://websmp202.sap-ag.de/support(Click on Request License key under Service Corner).
    Hope it helps.
    Regards
    Sourashree Ghosh

  • Calendar with Drill Down Report

    Hello,
    Everybody.
    I am new to Application Express.
    Please any one tell me step by step how to make calendar with drill down report.
    Waiting for valuable reply.
    Thanks
    Rahul

    Not sure if this is what you wanted, but I have links on a calendar, and when you click them, it branches to another page with details about the event.
    To do this, create a calendar region. The SQL statement should have at least 2 columns: The date of the "event", and the text to display as a link. You should also choose a primary key that you want to pass to the drill down report when the user clicks. Something like this:
    select hiredate date_scheduled,
              ename display_column,
              empno
       from empIn the calendar attributes of that region, there is a place to designate which column is the date, and which should be displayed. Go down a little further and set the column link. Put the page you want to show the drilldown report on, and set any variables you need to.
    Hopefully that helped. Its pretty simple once you play around with it - start simple and then once you get the hang of it, make it more complex.

  • Problem with drill down in time dimension - OBIEE 11G

    Hello There,
    I have a problem with drill down in time dimension. The hierarchy for time dimension is " Fiscal Year---> Fiscal Quarter---> Month(Name)--->Date". When I select a Time dimension and click results its getting opened in a Pivot table view. The problem here is, when I click the "Total" its getting drilled down to Year ---> Quarter but when I click on "+ sign next to quarter" it should drill down to month for that particular quarter for that particular year but its drilling down to month for that particular quarter for all years.
    Any suggestions are much appreciated.
    Thanks,
    Harry.

    1.) Congrats for resurrecting a year-old thread.
    2.) Your answer is here: "Check the level key of the quarter level...it should include both quarter and year columns. Since a specific quarter occurs every year, quarter column alone can't be used as the level key."

  • Suppressing sub-section with drill down OK

    This may be an easy one that I just cannot figure out (I hope...).
    I have created two details sections - details A and details B.  I would like to suppress details section B while still allowing for drill down capabilities.  However, that option is not available.  I can either suppress the entire details section (A and B) with drill down capabilities or suppress either A OR B with no drill down capabilities.
    Any and all help would be truly appreciated!!

    I can only think of using an on demand subreport which sits in Details b. but the row and the SR lable will be visible for all records.
    Ian

  • Problem in Viewer with drill down, Working fine in Plus

    Hi,
    I am using the cross tab reports with drill down functionality. In the viewer version I am getting the following error:
    An error occurred while handling the event. See the application log for more details.
    - The numerical value entered was too low.
    This one working fine in Plus. .
    As for your information this one is working fine in both plus and viewer in development instance and not working in PROD instance.
    Please help me out.
    thanks.

    Update
    Hi Guys the report is working fine with cross tab . Its giving the above error when ever I click the Drill to link which takes to the another detail report.
    thanks in advance

  • OBIEE-- Google Maps With Drill Down Facility

    Hi All,
    I want to create a map chart ie., google maps in OBIEE with drill down facility.
    This is my Hierarchy -> From country to state to city .
    I have this data in my table in the database as columns.
    I know to create google map but dont know how to include hierarchy, please let me know if this can be done.
    Thanks in Advance

    Firstly:
    http://catb.org/~esr/faqs/smart-questions.html#before
    Then look at:
    http://obiee101.blogspot.com/2009/03/obiee-google-maps-multiple-addresses.html
    http://www.artofbi.com/index.php/2009/07/obiee-and-google-maps-integration/

  • Required funnel with drill down

    Experts,
    Any sample example of Funnel Chart with drill down option available in Jdev 11.x ?
    thnks.

    Hi user 552235...
    I am not sure if my next post will help you, since I am not working with portal, but I had a problem with drill to link in the same disco version (10.1.2.48.18) and the problem solved after applying patch 5507746 for bug 5475467.
    You can read more in metalink with the number I supplied you and try in a test environment of course...
    Hope this will help you solving your problem, if it does please update the thread for the rest of our community...
    Gidi Halamish

  • ALV Reporting with drill down capabillities

    I'm creating a abap custom report using the ALV.  I want to drill down to CJ03 which is projects.  I know how to do it in regular custom reporting, but I don't seem to be able to get it to work using the ALV.  Can anyone help?
    Thanks.
    Linda

    Hi Linda,
    Take a look at this sample program. The logic to handle any interaction with the user is in my "PORCESS_USER_COMMANDS" routine.
    This is defined in the "I_CALLBACK_USER_COMMAND" parameter in the ALV FM.
    Hope this helps.
    Cheers,
    Pat.
    [code]
    Modification History
    Date      | Author    | Chg Req #     | Description
    15.08.2001| Pat Yee   | $TMP          | Program Creation
    This program is an example of how the ALV Display works.
    It will display Customer Data.
    This report will also show how to display an ALV report with different
    colored lines and icons
    REPORT zpat.
    Include Programs
    INCLUDE <icon>.
    Database Tables
    TABLES: kna1.                  "Customer Master
    Types
    TYPE-POOLS: kkblo.
    Structures
    Structure to hold the Color Information
    DATA: BEGIN OF st_color,
            color(3) TYPE c,
          END OF st_color.
    Structure to hold the Icon Information
    DATA: BEGIN OF st_icon,
            icon(4) TYPE c,
          END OF st_icon.
    ALV Field Catalog Structure
    DATA: st_fieldcat   TYPE slis_fieldcat_alv.
    ALV Layout Structure
    DATA: st_layout     TYPE slis_layout_alv.
    Internal Tables
    Output Table
    DATA: BEGIN OF tbl_kna1 OCCURS 0.
            INCLUDE STRUCTURE st_icon.   "Icon Structure
            INCLUDE STRUCTURE kna1.      "Customer Master Structure
            INCLUDE STRUCTURE st_color.  "Color Structure
    DATA: END OF tbl_kna1.
    ALV Field Catalog Table
    DATA: tbl_fieldcat  TYPE slis_t_fieldcat_alv.
    Variables
    DATA: fieldname(30) TYPE c,
          g_repid       LIKE sy-repid.
    Start of Selection
    START-OF-SELECTION.
      g_repid = sy-repid.
      PERFORM get_data.
    End of Selection
    END-OF-SELECTION.
      PERFORM do_fancy_stuff.
      PERFORM get_layout.
      PERFORM get_fieldcat.
      PERFORM create_report.
    *&      Form  CREATE_REPORT
          Learn to read the subroutine name!
    FORM create_report.
      CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
           EXPORTING
                i_interface_check       = ' '
                i_callback_program      = g_repid
                i_callback_user_command = 'PROCESS_USER_COMMANDS'
                it_fieldcat             = tbl_fieldcat
                i_default               = 'X'
                i_save                  = ' '
                is_layout               = st_layout
           TABLES
                t_outtab                = tbl_kna1
           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.                               " CREATE_REPORT
    *&      Form  GET_FIELDCAT
          Build the Field Catalog
    FORM get_fieldcat.
    Here the field catalog is created. To display more fields simply
    'uncomment' the additional lines and add the field name. Also note
    that the field catalog is much more powerful than this. You can
    intensify fields, change the colour, assign reference fields, etc.
    Look at type slis_fieldcat_alv for more options.
      PERFORM write_fieldcat USING 'ICON'  'TBL_KNA1' '    ' 'X' 1 '2' 'X'
      PERFORM write_fieldcat USING 'KUNNR' 'TBL_KNA1' 'KNA1' 'X' 2 ' ' ' '
      PERFORM write_fieldcat USING 'NAME1' 'TBL_KNA1' 'KNA1' ' ' 3 '10' ' '
                                   'X'.
      PERFORM write_fieldcat USING 'STRAS' 'TBL_KNA1' 'KNA1' ' ' 4 ' ' ' '
      PERFORM write_fieldcat USING 'TELF1' 'TBL_KNA1' 'KNA1' ' ' 5 ' ' ' '
      PERFORM write_fieldcat USING 'ORT01' 'TBL_KNA1' 'KNA1' ' ' 6 ' ' ' '
      PERFORM write_fieldcat USING 'PSTLZ' 'TBL_KNA1' 'KNA1' ' ' 7 ' ' ' '
      PERFORM write_fieldcat USING 'SORTL' 'TBL_KNA1' 'KNA1' ' ' 8 ' ' ' '
      PERFORM write_fieldcat USING 'ERNAM' 'TBL_KNA1' 'KNA1' ' ' 9 ' ' ' '
      PERFORM write_fieldcat USING 'SPRAS' 'TBL_KNA1' 'KNA1' ' ' 10 ' ' ' '
    perform write_fieldcat using '     ' 'TBL_KNA1' 'KNA1' ' ' 10 ' '.
    perform write_fieldcat using '     ' 'TBL_KNA1' 'KNA1' ' ' 11 ' '.
    perform write_fieldcat using '     ' 'TBL_KNA1' 'KNA1' ' ' 12 ' '.
    ENDFORM.                               " GET_FIELDCAT
    *&      Form  WRITE_FIELDCAT
          Write the Field Catalog data to the Field Catalog Table
         -->name   Field name
         -->tab    Table name
         -->st     Structure Name
         -->key    Is this field a Key?
         -->pos    Position Number
         -->length Field Length
         -->icon   Display as Icon
         -->hot    Hotspot
    FORM write_fieldcat USING name tab st key pos length icon hot.
      st_fieldcat-fieldname   = name.
      st_fieldcat-tabname     = tab.
      st_fieldcat-ref_tabname = st.
      st_fieldcat-key         = key.
      st_fieldcat-col_pos     = pos.
      st_fieldcat-outputlen   = length.
      st_fieldcat-icon        = icon.
      st_fieldcat-hotspot     = hot.
      APPEND st_fieldcat TO tbl_fieldcat.
      CLEAR st_fieldcat.
    ENDFORM.                               " WRITE_FIELDCAT
    *&      Form  PROCESS_USER_COMMANDS
          Interactive Reporting Commands
    FORM process_user_commands USING syst-ucomm LIKE syst-ucomm
                                     selfield TYPE slis_selfield.
    This subroutine is called when there is user interaction in the output
    In this case if the user double clicks the Customer Number then the
    program will call transaction XD03 and display the Customer Master
    Data
      CASE syst-ucomm.
        WHEN '&IC1'.
    get cursor field fieldname.
          READ TABLE tbl_kna1 INDEX selfield-tabindex.
          SET PARAMETER ID 'KUN' FIELD tbl_kna1-kunnr.
          CALL TRANSACTION 'XD03' AND SKIP FIRST SCREEN.
      ENDCASE.
    ENDFORM.                               " PROCESS_USER_COMMANDS
    *&      Form  GET_LAYOUT
      set the layout of the ALV.
      add color to the row?
    FORM get_layout.
      st_layout-info_fieldname    = 'COLOR'.
      st_layout-colwidth_optimize = 'X'.
      st_layout-get_selinfos      = 'X'.
    ENDFORM.                    " GET_LAYOUT
    *&      Form  get_data
          Get some data to play with
    FORM get_data.
      SELECT * FROM kna1 INTO CORRESPONDING FIELDS OF TABLE tbl_kna1
             UP TO 30 ROWS.
    ENDFORM.                    " get_data
    *&      Form  do_fancy_stuff
          Do some fancy pants stuff for example changing the color of
          lines and adding icons
    FORM do_fancy_stuff.
    Here we will demonstrate changing the color of ALV Record lines as
    well as displaying Icons
      LOOP AT tbl_kna1.
    All records where NAME1 begins with 'M', will be displayed in Bluish
    Green
        IF tbl_kna1-name1(1) EQ 'M'.
          tbl_kna1-color = 'C41'.  "Bluish Green
          MODIFY tbl_kna1 TRANSPORTING color.
        ENDIF.
    All records with no TELF1 will be displayed in White and have a
    Warning Icon
        IF tbl_kna1-telf1 IS INITIAL.
          tbl_kna1-color = 'C00'.  "White
          tbl_kna1-icon  = '@AH@'. "Warning Icon
          MODIFY tbl_kna1 TRANSPORTING icon color.
        ENDIF.
      ENDLOOP.
    ENDFORM.                    " do_fancy_stuff[/code]

  • Layout problem for Drill down ALV Report

    Hello Everyone,
                           I have developed a ALV drill down report using the method G_GRID->SET_TABLE_FOR_FIRST_DISPLAY. The problem is what ever layout i save for the primary list 'Screen 100' is effecting my secondary list 'Screen 200'.  User need to save both Screen 100 and Screen 200 layouts independently without affecting each other.
    I am calling  screen 100 as below,
    Call metthod g_grid_100->set_table_for_first_display
      Exporting
       i_Save                                     = 'A'
       is_layout                                 =  ls_layout
       is_Variant                                =   ls_Variant
      Changing
       it_outtab                                  =  ct_poitems
       it_fieldcatalog                           =  lt_fieldcat
      Exceptions
       Invalid_parameter_combimation   = 1
       Program_error                            = 2
       too_many_lines                         = 3
       others                                       = 4.
    Could any body suggest me a way to do this..
    Thanks in advance.
    Regards,
    Shyam.

    Hi,
    Use multiple Layout structure (each alv have its own structure) .
    Note the use of disvariant-log_group .
    DATA: gs_disvariant_1 TYPE disvariant ,
               gs_disvariant_2 TYPE disvariant .
    * Layout-Logical groups
    CONSTANTS: gc_log_group_1 TYPE disvariant-log_group VALUE 'ALV1' ,
                            gc_log_group_2 TYPE disvariant-log_group VALUE 'ALV2' .  
    INITIALIZATION.
      PERFORM at_initialization .
    FORM at_initialization .
    DATA: vari TYPE disvariant-variant .
      PERFORM alv_variant_get_default USING gc_log_group_1 CHANGING gs_disvariant_1 vari .
      PERFORM alv_variant_get_default USING gc_log_group_2 CHANGING gs_disvariant_2 vari .
    ENDFORM.
    FORM alv_variant_get_default
      USING
        log_group TYPE disvariant-log_group
      CHANGING
        disvariant TYPE disvariant
        variant    TYPE slis_vari .
      DATA: ls_disvariant TYPE disvariant.
      ls_disvariant-report = sy-repid .
      ls_disvariant-log_group = log_group .
      disvariant = ls_disvariant.
      CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET'
        EXPORTING
          i_save     = 'A'
        CHANGING
          cs_variant = ls_disvariant
        EXCEPTIONS
          not_found  = 2.
      IF sy-subrc = 0.
        disvariant = ls_disvariant.
        variant    = ls_disvariant-variant .
      ENDIF.
    ENDFORM.                    "alv_variant_get_default
    Later....
       CALL METHOD gui_alv_grid_1->set_table_for_first_display
          EXPORTING
            is_layout       = wa_layout
            is_print        = wa_print
            i_save          = 'A'
            is_variant      = gs_disvariant_1
          CHANGING
            it_sort         = it_sort
            it_fieldcatalog = it_fieldcatalog
            it_outtab       = it_alv_grid_1.
      CALL METHOD gui_alv_grid_2->set_table_for_first_display
          EXPORTING
            is_layout       = wa_layout
            is_print        = wa_print
            i_save          = 'A'
            is_variant      = gs_disvariant_2
          CHANGING
            it_sort         = it_sort
            it_fieldcatalog = it_fieldcatalog
            it_outtab       = it_alv_grid_2.     
    Regards.

  • Error in Drilled down ALV Report.

    Hi all
    i am creating a single level drilled down report , in that in the first screen i am displaying the header detials , in the second level i am displaying the item detial of the particular line..
    While processing the second level i am getting a dump like
    A PERFORM was used to call the routine "USER_COMMAND" of the program
    "SAPLSLVC_FULLSCREEN".
    This routine contains exactly 1 formal parameters, but the current
    call contains 2 actual parameters.
    parameters.
    here is my code :
    FORM USER_COMMAND USING R_UCOMM LIKE SY-UCOMM.
    CASE R_UCOMM.
    WHEN '&IC1'.
    PERFORM BUILD_CATALOG_EKPO.
    PERFORM EVENT_EKPO.
    PERFORM POPULATE_EVENT_EKPO.
    PERFORM DATA_EKPO.
    PERFORM BUILD_LIST.
    PERFORM DISPLAY_EKPO.
    ENDCASE.
    ENDFORM.
    *&      Form  BUILD_CATALOG_EKPO
          text
    -->  p1        text
    <--  p2        text
    FORM BUILD_CATALOG_EKPO .
      WA_FIELDCAT-TABNAME = 'ITAB_EKPO'.
      WA_FIELDCAT-FIELDNAME = 'EBELN'.
      WA_FIELDCAT-SELTEXT_M = 'PO NO.'.
      APPEND WA_FIELDCAT TO I_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-TABNAME = 'ITAB_EKPO'.
      WA_FIELDCAT-FIELDNAME = 'EBELP'.
      WA_FIELDCAT-SELTEXT_M = 'Item No.'.
      APPEND WA_FIELDCAT TO I_FIELDCAT.
      CLEAR WA_FIELDCAT.
        WA_FIELDCAT-TABNAME = 'ITAB_EKPO'.
      WA_FIELDCAT-FIELDNAME = 'MATNR'.
      WA_FIELDCAT-SELTEXT_M = 'Material NO.'.
      APPEND WA_FIELDCAT TO I_FIELDCAT.
      CLEAR WA_FIELDCAT.
        WA_FIELDCAT-TABNAME = 'ITAB_EKPO'.
      WA_FIELDCAT-FIELDNAME = 'WERKS'.
      WA_FIELDCAT-SELTEXT_M = 'PLANT.'.
      APPEND WA_FIELDCAT TO I_FIELDCAT.
      CLEAR WA_FIELDCAT.
        WA_FIELDCAT-TABNAME = 'ITAB_EKPO'.
      WA_FIELDCAT-FIELDNAME = 'LGORT'.
      WA_FIELDCAT-SELTEXT_M = 'Storage Loc.'.
      APPEND WA_FIELDCAT TO I_FIELDCAT.
      CLEAR WA_FIELDCAT.
        WA_FIELDCAT-TABNAME = 'ITAB_EKPO'.
      WA_FIELDCAT-FIELDNAME = 'MENGE'.
      WA_FIELDCAT-SELTEXT_M = 'Quantity.'.
      APPEND WA_FIELDCAT TO I_FIELDCAT.
      CLEAR WA_FIELDCAT.
        WA_FIELDCAT-TABNAME = 'ITAB_EKPO'.
      WA_FIELDCAT-FIELDNAME = 'MEINS'.
      WA_FIELDCAT-SELTEXT_M = 'UNIT.'.
      APPEND WA_FIELDCAT TO I_FIELDCAT.
      CLEAR WA_FIELDCAT.
    ENDFORM.                    " BUILD_CATALOG_EKPO
    *&      Form  EVENT_EKPO
          text
    -->  p1        text
    <--  p2        text
    FORM EVENT_EKPO .
    CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
    EXPORTING
      I_LIST_TYPE           = 0
    IMPORTING
       ET_EVENTS             = V_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.
    ENDFORM.                    " EVENT_EKPO
    *&      Form  POPULATE_EVENT_EKPO
          text
    -->  p1        text
    <--  p2        text
    FORM POPULATE_EVENT_EKPO .
    READ TABLE V_EVENTS INTO WA_EVENT WITH KEY NAME = 'TOP_OF_PAGE'.
    IF SY-SUBRC EQ 0.
    WA_EVENT-FORM = 'TOP_OF_PAGE'.
    MODIFY V_EVENTS FROM WA_EVENT TRANSPORTING FORM WHERE NAME = WA_EVENT-FORM.
    ENDIF.
    ENDFORM.                    " POPULATE_EVENT_EKPO
    FORM F_TOP_OF_PAGE.
      CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
        EXPORTING
          IT_LIST_COMMENTARY       = IT_LISTHEADER
       i_logo                   =
       I_END_OF_LIST_GRID       =
    ENDFORM.
    *&      Form  DATA_EKPO
          text
    -->  p1        text
    <--  p2        text
    FORM DATA_EKPO .
    DATA:RS_SELFIELD TYPE SLIS_SELFIELD.
    READ TABLE ITAB_EKKO INTO WA_EKKO INDEX RS_SELFIELD-TABINDEX.
    SELECT EBELN EBELP MATNR WERKS LGORT MENGE MEINS
    FROM EKPO
    INTO CORRESPONDING FIELDS OF TABLE ITAB_EKPO
    WHERE EBELN = WA_EKKO-EBELN.
    DATA :ID_ITEM_COLOR.
    LOOP AT ITAB_EKPO INTO WA_EKPO.
    ID_ITEM_COLOR = ID_ITEM_COLOR + 1.
    IF ID_ITEM_COLOR = 8.
       ID_ITEM_COLOR = 1.
    ENDIF.
    CONCATENATE 'C' ID_ITEM_COLOR '10' INTO WA_EKPO-LINE_COLOR_ITEM.
    MODIFY ITAB_EKPO FROM WA_EKPO TRANSPORTING LINE_COLOR_ITEM.
    ENDLOOP.
    ENDFORM.                    " DATA_EKPO
    *&      Form  DISPLAY_EKPO
          text
    -->  p1        text
    <--  p2        text
    FORM DISPLAY_EKPO .
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
    EXPORTING
      I_INTERFACE_CHECK                 = ' '
      I_BYPASSING_BUFFER                = ' '
      I_BUFFER_ACTIVE                   = ' '
       I_CALLBACK_PROGRAM                 = V_REPID
      I_CALLBACK_PF_STATUS_SET          = ' '
      I_CALLBACK_USER_COMMAND           = '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_TITLE_EKPO
      I_GRID_SETTINGS                   =
      IS_LAYOUT                         =
       IT_FIELDCAT                       = I_FIELDCAT[]
      IT_EXCLUDING                      =
      IT_SPECIAL_GROUPS                 =
      IT_SORT                           =
      IT_FILTER                         =
      IS_SEL_HIDE                       =
      I_DEFAULT                         = 'X'
      I_SAVE                            = ' '
      IS_VARIANT                        =
       IT_EVENTS                         = V_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
      IT_ALV_GRAPHICS                   =
      IT_HYPERLINK                      =
      IT_ADD_FIELDCAT                   =
      IT_EXCEPT_QINFO                   =
      I_HTML_HEIGHT_TOP                 =
      I_HTML_HEIGHT_END                 =
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER           =
      ES_EXIT_CAUSED_BY_USER            =
      TABLES
        T_OUTTAB                          = ITAB_EKPO
    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_EKPO
    *&      Form  BUILD_LIST
          text
    -->  p1        text
    <--  p2        text
    FORM BUILD_LIST .
      gd_layout-no_input          = 'X'.
      gd_layout-colwidth_optimize = 'X'.
      gd_layout-totals_text       = 'Totals'(201).
    Set layout field for row attributes(i.e. color)
      gd_layout-info_fieldname =      ' LINE_COLOR_ITEM'.
    ENDFORM.                    " BUILD_LIST
    Arun Joseph

    The form USER_COMMAND should have 2 changing/actual parameters which is standard.
    Ex:
    FORM user_command USING r_ucomm LIKE sy-ucomm 
    rs_selfield TYPE slis_selfield.
    ENDFORM.

  • Dynamic filter with drill down in WAD

    Hello Expert,
    I am new in WAD and I have a requirement as below:
    Data in Provider:
    Mat1  Mat2   Plant   qty
    M1     M2       P1      10
    M1     M2       P2       20
    Report layout in Bex as below:
    Row:
    Mat1
    Column:
    Qty
    Free char:
    Mat2
    Initially I open the WAD report, data should filter on Plant = P1
    Output:
    Mat1  qty
    M1     10
    Now If I right click on Mat1 (select filter value and drill on Mat2 level) data get filter on Plant = P2, it show as below
    Mat2  qty
    M2    20
    How I can achieve in WAD.
    Thanks in advance!!!
    Regards,
    Abhishek

    You can restrict the value in variable screen with default value plant as "P1" and added the query to template. Now you can executed the query in portal you drill down through context ment filter -> filter on value then select the value to "P2" and add it then click "OK" it will show only P2 value. http://help.sap.com/saphelp_nw73/helpdata/en/44/33eb19e2173ec8e10000000a1553f6/content.htm https://help.sap.com/saphelp_nw73/helpdata/en/43/152fa54b315a38e10000000a422035/content.htm

  • Master detail view with drill down

    I am trying to develop a simple app for my Ipad. This app is supposed to have a Master/details look and should behave similar to the native Mail app (2x levels of navigation and the last level updates the details view).
    My problem is that I am not familiar to Apple IOS development so tend to get stuck all the time so I prefer to follow a tutorial or start with a sample project. I have searched for hours but I always either get a pure navigation drill down project without the details view or a pure master/details project with only a single level of navigation. I tried to take these projects and modify them but my knowledge sadly is very limited and I did not succeed.
    So can anybody direct me to a tutorial or a sample project where a Mail like app is being built with more than 1 level of navigation ?

    I have a GridBagLayout panel with a jtable and some jtextfield Well, we don't know exactly what constraints you have set up to its hard to say exactly why its happening.
    In general, you should create your JTextField using new JTextField(int) and I think the problem will go away.
    An easier solution would also be to use different LayoutManagers to achieve the desired layout.

  • Issue with drill down in Financial Reporting 11.1.2.2

    Hi All,
    I have a requirement like this :
    I have different dimensions for Year and Period(Period has half years and also quarters ).
    The requirement is like that when the report opens up the rport should look like this:
                             YearTotal
                        FY12            FY13
    Accounts
    Now the user  wants to drill down on YearTotal and it should show in the following way:
                               H1                      H2
                     FY12      FY13    FY12      FY13
    Accounts
    and so on.
    Still now whatever I have tried I am unable to acheive this . Any ideas whther this is acheivable or not ????
    Regards,
    Saurav

    Even without drill(allow expansion) you can only achieve that only by using merge option.
    With merge the drill will not work.
    It'll not be a pretty report.
    Regards
    Celvin
    http://www.orahyplabs.com

  • Viewing reports with Drill Down option

    Hi all, here is the complaint that we received:
    Please try to find a means to help!
    When I’m in my Report and when in an account and I go to a deal to alter or look at it, when I return to reports I always am driven back to the top of the report file. If I’m in December and looking at the entire year I have to go through all accounts once again to get to the same starting point. A great irritant. I can’t help but think that there is a better way.
    Anyone know if this can be changed? Thank you in advance!!!

    Sorry, let me explain...
    The problem isn't with the report, they have issues with what happens after you drill down into the account from the report and go back to the report.
    When they go back to the report after adjusting the account/opp it doesn;t go back to what they were looking at, the view will go to the top of the report. Say they were looking at Account #100 out of 250 (250 total accounts in the report), if they drill down into account 100 and then go back to the report they will be taken back to account #1.
    Is that more clear?
    What they want is to be able to go back to the view of Account #100.

Maybe you are looking for

  • How can I search the tree with a given string?

    How can I search the tree with a given string? I don't find any function like "search(...)". I want to find the tree nodes which include the given string. Thanks.

  • I want Report Server details.

    In which Version of CD, Oracle Developer Server (especially Report Server) is available. What is the deployment restrictions available in report server? and Let me know the Price of it.

  • Apple Student Program for Colombia?

    Hi there, I've being searching the whole site, trying to find a number or an email to send this inquiry to but I couldn't so Had no other choise but to post this on the Discussions hoping for someone in the high roll to see this post. I've being a wa

  • Problem in thread to post code

    hello Please check the following thread in this thread when i post code then preview is not perfert only problem in this thread not othere Re: Hierarchical sequential List

  • Please help me on UNBOUNDED PRECEDING and CURRENT ROW

    Helllo Experts, Kindly help me on below query.. SELECT    SUM(n) AS month_amount,   SUM(SUM(n)) OVER     (ORDER BY n ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW)     AS cumulative_amount   FROM t1   GROUP BY n   ORDER BY n;Here i need explanatio