Skip to Content
author's profile photo Former Member
Former Member

MODULE for ALV grid with selection

Greetings,

I'm in the midst of writing a dialogue application where based upon my screen 1100's entries a subsequent screen is called and an ALV grid is shown where my user can select entries within the ALV grid. The grid is to be filled with data from internal table. My struggle at the moment is building the ALV with the check boxes for selecting entries. I can put my data on the screen in a grid but not with select box capabilites. Any help of sample code or demo program in SAP 46C is appreciated.

Thanks!

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

1 Answer

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Nov 14, 2007 at 08:28 PM
    Add a comment
    10|10000 characters needed characters exceeded

    •   DATA:
          wa_layout TYPE slis_layout_alv .
      
      
      wa_layout-BOX_fieldname = 'CHECK'.   " << this will allow you to select the your Check box
      
      CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
         EXPORTING
      *   I_INTERFACE_CHECK                 = ' '
      *   I_BYPASSING_BUFFER                = ' '
      *   I_BUFFER_ACTIVE                   = ' '
          i_callback_program                = sy-cprog
      *   I_CALLBACK_PF_STATUS_SET          = ' '
          i_callback_user_command           = 'USER_COMMAND'
      *   I_CALLBACK_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                         = wa_layout
            it_fieldcat                       = t_fcat_summary
      *   IT_EXCLUDING                      =
      *   IT_SPECIAL_GROUPS                 =
      *   IT_SORT                           =
      *   IT_FILTER                         =
      *   IS_SEL_HIDE                       =
      *   I_DEFAULT                         = 'X'
            i_save                            = 'A'
      *   IS_VARIANT                        =
      *   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                          = t_summary
         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.

      Regards,

      Naimesh Patel

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.