Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Selecting multiple line items with checkbox in ALV output

Former Member
0 Kudos

Hi experts,

I am developing an ALV report using reuse_alv_grid_display where the user wants the ability to select individual line items with a chekbox in the output. Once he has done this he clicks on a custom button the toolbar after which a BDC is triggered.

I have already copied the standard toolbar and customized it by adding the buttons on the toolbar. However now when i select a single line item using the checkbox it works fine. However, if i select multiple line items (as per requirement) then it just takes the last selected line item into consideration. For ex: if i select line items 2 and 4, then only line item 4 is taken.

I cannot use the line select option on the far left of the ALV output as the user wants a checkbox.

I would appreciate any help on this.

Regards,

Ritwik

1 ACCEPTED SOLUTION

lijisusan_mathews
Active Contributor
0 Kudos

Hi Ritwik,

Can you please mention how you are retrieving the values for multiple lines??? Or if you can please insert the relevant coding that you have done for the same .

Suzie

36 REPLIES 36

lijisusan_mathews
Active Contributor
0 Kudos

Hi Ritwik,

Can you please mention how you are retrieving the values for multiple lines??? Or if you can please insert the relevant coding that you have done for the same .

Suzie

0 Kudos

Hello Suzie,

Thanks for the quick response. I am fetching the data into an internal table and hen displaying it using the FM REUSE_ALV_GRID_DISPLAY.

And in the of-status and USER_COMMAND the following is the code:

FORM set_pf_status USING rt_extab TYPE slis_t_extab.

SET PF-STATUS 'ZSCREEN'.

ENDFORM. "Set_pf_status

FORM user_command USING ucomm LIKE sy-ucomm

selfield TYPE slis_selfield.

DATA: lv_ucomm TYPE sy-ucomm.

lv_ucomm = sy-ucomm.

CASE lv_ucomm.

WHEN '&APPROVE'.

  • when '&ITM'.

LOOP AT it_zfi_db_cr INTO wa_zfi_db_cr WHERE chk = 'X'.

**BDC code***

ENDLOOP.

*endcase.

WHEN '&REJECT'.

**some code**

WHEN '&REF'.

**some code**

ENDCASE.

ENDFORM. "user_command

&APPROVE, &REJECT and &REF are the custom buttons i have added to the copy of the standard toolbar. I have added the box_fieldname as gd_layout-box_fieldname = 'CHK'.

Please let me know in case you need any further details.

Regards,

Ritwik

0 Kudos

When you call your REUSE_ALV_GRID_DISPLAY function,

It will have an importing parameter I_GRID_SETTINGS..

This is a structure.. In this structure the value of the field EDT_CLL_CB should be set to 'X'..

Try this and get back if it is not useful

Suzie

0 Kudos

Hello,

@Suzie ...

i tried what you suggested, however i got a dump saying 'Field symbol has not yet been assigned' ... could you please clarify. Do i need to do something else.

@Dez_

I am getting an dump again saying 'Access via 'NULL' object reference not possible' .

Regards,

Ritwik

0 Kudos

Please confirm if this is what you have passed to the i_grid_settings..

data wa_grid type LVC_S_GLAY.

wa_grid-EDT_CLL_CB = 'X'

REUSE_ALV_GRID_DISPLAY

.

importing.

. { other lines)

.

.

I_GRID_SETTINGS = wa_grid

.

.

. { other lines)

.

if a Dump still occurs , can you please write the description of the dump

Suzie

0 Kudos

Hi Suzie,

Yes those are the exact sequence of parameters that i have passed. Just for your reference i have defined it as:

Data: wa_lvc type lvc_s_glay.

and the rest is the same as you mentioned earlier.

The following are the details of the dump:

Short text

Field symbol has not yet been assigned.

What happened?

Error in the ABAP Application Program

The current ABAP program "CL_GUI_ALV_GRID===============CP" had t

terminated because it has

come across a statement that unfortunately cannot be executed.

Error analysis

You attempted to access an unassigned field symbol

(data segment 32781).

This error may occur if

- You address a typed field symbol before it has been set with

ASSIGN

- You address a field symbol that pointed to the line of an

internal table that was deleted

- You address a field symbol that was previously reset using

UNASSIGN or that pointed to a local field that no

longer exists

- You address a global function interface, although the

respective function module is not active - that is, is

not in the list of active calls. The list of active calls

can be taken from this short dump.

Trigger Location of Runtime Error

Program CL_GUI_ALV_GRID===============CP

Include CL_GUI_ALV_GRID===============CM03B

Row 228

Module type (METHOD)

Module Name SPLIT_GOOD_AND_BAD

Hope this helps. Please let me know in case you need any further details.

Regards,

Ritwik

0 Kudos

Can you try 2 small things..

1. Double- Check if the whole( any includes or anything ) of your program is activated.

2. Instead of directly passing value 'X' to EDT_CLL_CB try doing this

wa_lvc-EDT_CLL_CB = w_check

where w_check id declared as

data w_check type LVC_EDTCB .

w_check = 'X'.

Suzie

0 Kudos

You are using REUSE_ALV_GRID_DISPLAY right ? not classes no ?

0 Kudos

Hi Suzie,

I tried what you suggested ... however i am getting the same dump. Yes, i am using FM REUSE_ALV_GRID_DISPLAY ... no classes.

Regards,

Ritwik

0 Kudos

Ok.. In this case... Lets try something else..

But b4 that, just comment that line for grid settings and check again if there is any dump.. Just to be sure that i_grid_settings was the reason for the Dump...

If dump not formed now, write the following code in the beginning of user command

DATA: o_object TYPE REF TO cl_gui_alv_grid.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

e_grid = o_object.

CALL METHOD o_object->check_changed_data.

0 Kudos

hello,

you are getting dump because you did not define alv_grid object (my suggestion was to use class instead of FM).Use OO alv.

define global data:

data: gv_container_alv  type ref to cl_gui_custom_container,
      gv_alv_grid       type ref to cl_gui_alv_grid,
      gt_fieldcat       type lvc_t_fcat,
      gs_layout         type lvc_s_layo.

at PBO create alv_grid object

if gv_alv_grid is initial.

    data: lt_exclude type ui_functions.

    create object gv_container_alv
      exporting
        container_name              = 'CONTAINERS NAME'
      exceptions
        cntl_error                  = 1
        cntl_system_error           = 2
        create_error                = 3
        lifetime_error              = 4
        lifetime_dynpro_dynpro_link = 5
        others                      = 6.

    create object gv_alv_grid
      exporting
        i_parent          = gv_container_alv
      exceptions
        error_cntl_create = 1
        error_cntl_init   = 2
        error_cntl_link   = 3
        error_dp_create   = 4
        others            = 5.

    perform prepare_field_catalog changing gt_fieldcat .
    perform prepare_layout changing gs_layout .

    call method gv_alv_grid->set_table_for_first_display
      exporting
        is_variant                    = g_variant
        is_layout                     = gs_layout
      changing
        it_outtab                     = gt_outtab
        it_fieldcatalog               = gt_fieldcat
      exceptions
        invalid_parameter_combination = 1
        program_error                 = 2
        too_many_lines                = 3
        others                        = 4.

  else.
    call method gv_alv_grid->refresh_table_display
      exceptions
        finished = 1
        others   = 2.
  endif.

i wrote in previous post how you should define fieldcatalog.

and how to read data with filled checkbox.

.br,

dez_

0 Kudos

Hi Suzie,

You were right the moment i commented the i_grid_settings parameter in the FM i did not get a dump (the good news) ...

However i added the code as you suggested in the user comand and now it gives the dump at the the line CALL METHOD o_object->check_changed_data.

I have added the code as follows:

FORM user_command USING ucomm LIKE sy-ucomm

selfield TYPE slis_selfield.

DATA: lv_ucomm TYPE sy-ucomm.

lv_ucomm = sy-ucomm.

DATA: o_object TYPE REF TO cl_gui_alv_grid.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

e_grid = o_object.

CALL METHOD o_object->check_changed_data.

CASE lv_ucomm.

WHEN '&APPROVE'.

LOOP AT it_zfi_db_cr INTO wa_zfi_db_cr WHERE chk = 'X'.

***BDC runs**

ENDLOOP.

WHEN '&REJECT'.

***some code***

WHEN '&REF'.

***some code***

ENDCASE.

ENDFORM. "user_command

Do let me know if there's any issues with the code.

Regards,

Ritwik

0 Kudos

ok.. i tried finding out teh reason of your dump.. adn i Think it should be triggered at point

      • Formal field check with DDIC reference

call method me->formal_field_check_ddic

This is a method in cl_gui_alv_grid..

So simply guessing from the comments above the method,

Can you just check if you fieldcatalog fields are all assigned properly..especially any fields with dictionary reference ?

O can you check if the declaration for the check box field in the internal table is type char01?

Edited by: Suzie on Jul 12, 2011 1:22 PM

0 Kudos

@Dez_

Thanks for the reply. Are you saying that this feature is not possible in normal ALV reports?

@Suzie

so are you saying that i need to call the method formal_field_check_ddic within the class CL_GUI_ALV_GRID.

I tried that however i got an error message on activation that 'Method 'FORMAL_FIELD_CHECK_DDIC' is unknown or protected or private.

The field catalogs are ok cos i can see the ALV display properly. It's only when i select the checkbox of the line item and press the button that i get the dump.

I have defined the checkbox as:

TYPES: BEGIN OF s_zfi_db_cr,

chk(1) TYPE c.

INCLUDE STRUCTURE zfi_db_cr.

TYPES: END OF s_zfi_db_cr.

@PriyankaVerma

I have already tried that Priyanka ... but the dump continues.

0 Kudos

@Suzie

ok now i have called the method formal_field_check_ddic but what would be the parameters to be passed here ...

Regards,

Ritwik

0 Kudos

you dont need to add the method.. it is the standard code in the methods that we have already called ...... You can find it if you go into cl_gui_alv_grid.. ie.. if you find teh exact method where your dump occured..

Can you... show me the part where you have added this in your field catalog..

Suzie

0 Kudos

I have defined the field catalog as follows:

wa_fieldcat-col_pos = 1.

wa_fieldcat-fieldname = 'CHECK'.

  • wa_fieldcat-seltext_m = 'Check Row'.

wa_fieldcat-ref_tabname = 'IT_ZFI_DB_CR'.

wa_fieldcat-checkbox = 'X'.

  • wa_fieldcat-input = 'X'.

wa_fieldcat-outputlen = 1.

wa_fieldcat-edit = 'X'.

APPEND wa_fieldcat TO it_fieldcat.

CLEAR wa_fieldcat.

wa_fieldcat-col_pos = 2.

wa_fieldcat-fieldname = 'REFERENCENO'.

wa_fieldcat-ref_tabname = 'IT_ZFI_DB_CR'.

  • wa_fieldcat-tabname = 'TAB_ETAB'.

wa_fieldcat-seltext_m = 'Reference Number'.

wa_fieldcat-seltext_l = 'Reference Number'.

APPEND wa_fieldcat TO it_fieldcat.

CLEAR wa_fieldcat.

wa_fieldcat-col_pos = 3.

wa_fieldcat-fieldname = 'DOCUMENTDT'.

wa_fieldcat-ref_tabname = 'IT_ZFI_DB_CR'.

  • wa_fieldcat-tabname = 'TAB_ETAB'.

wa_fieldcat-seltext_m = 'Document Date'.

wa_fieldcat-seltext_l = 'Document Date'.

APPEND wa_fieldcat TO it_fieldcat.

CLEAR wa_fieldcat.

wa_fieldcat-col_pos = 4.

wa_fieldcat-fieldname = 'CUSTOMERCODE'.

wa_fieldcat-ref_tabname = 'IT_ZFI_DB_CR'.

  • wa_fieldcat-tabname = 'TAB_ETAB'.

wa_fieldcat-seltext_m = 'Customer Code'.

wa_fieldcat-seltext_l = 'Customer Code'.

APPEND wa_fieldcat TO it_fieldcat.

CLEAR wa_fieldcat.

wa_fieldcat-col_pos = 5.

wa_fieldcat-fieldname = 'VENDORCODE'.

wa_fieldcat-ref_tabname = 'IT_ZFI_DB_CR'.

  • wa_fieldcat-tabname = 'TAB_ETAB'.

wa_fieldcat-seltext_m = 'Vendor Code'.

wa_fieldcat-seltext_l = 'Vendor Code'.

APPEND wa_fieldcat TO it_fieldcat.

CLEAR wa_fieldcat.

and so on for the rest of the fields ... The layout function is defined as

FORM build_layout .

gd_layout-no_input = 'X'.

gd_layout-colwidth_optimize = 'X'.

ENDFORM.

Regards,

Ritwik

0 Kudos

Sorry if i confused you.. You do not have to call the method.. It is already called when you set the i_grid_settings and when we call the check_data_change method..

This is an error that is being caused to some change in the ALV parameters or fieldcatalog.. It might be something too small.. wE just need to figure it out..

0 Kudos

Ok...

make the following changes please...

In layout..

gd_layout-no_input = 'X'. Dont add anything in layout

In field catalog

wa_fieldcat-col_pos = 1.

wa_fieldcat-fieldname = 'CHECK'.

* wa_fieldcat-seltext_m = 'Check Row'.

wa_fieldcat-ref_tabname = 'IT_ZFI_DB_CR'.

wa_fieldcat-checkbox = 'X'.

  • wa_fieldcat-input = 'X'.

wa_fieldcat-outputlen = 1.

wa_fieldcat-edit = 'X'.

APPEND wa_fieldcat TO it_fieldcat.

CLEAR wa_fieldcat.

now try

0 Kudos

Ok thanks ... I have noticed that it gives a dump at statement:

call method cl_gui_cfw=>dispatch.

... in the include LSLVC_FULLSCREENF01 of the program SAPLSLVC_FULLSCREEN

but haven't figured out wht yet ...

Regards,

Ritwik

0 Kudos

Hi Suzie,

I tried those changes, but the dump is still coming ... at the point where i have mentioned above.

Regards,

Ritwik

0 Kudos

can you replace the following line too

lv_ucomm = sy-ucomm.

with

lv_ucomm = ucomm.

SuZie

0 Kudos

Hi Suzie,

It never gets to the user_command code. Like i said it gives a dump within the standard code i.e. include LSLVC_FULLSCREENF01 within the main program SAPLSLVC_FULLSCREEN.

Regards,

Ritwik

0 Kudos

This is the code you have written right ???

dATA: lv_ucomm TYPE sy-ucomm.

lv_ucomm = sy-ucomm.

DATA: o_object TYPE REF TO cl_gui_alv_grid.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

e_grid = o_object.

CALL METHOD o_object->check_changed_data.

and the dump still occurs at the CALL METHOD o_object->check_changed_data. right ??

In that case, please try replacing sy-ucomm with ucomm.

If the dump is not triggered at CALL METHOD o_object->check_changed_data... , can you mention, where in your Z program the dump is getting triggered now ?

Suzie

0 Kudos

Hi Suzie,

I have set a breakpoint there. However now when i select the checkbox for a line item in the ALV output - and before i can even click the Approve button (custom button that i have added) on the menu bar it goes to the program and include that i mentioned earlier and throws that dump.

I have observed that this is cos of assigning the i_grid_settings parameter in reuse_alv_grid_display.

If i don't do that (i.e. if i comment that line) then it goes to the code in user_command:

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

e_grid = o_object.

IF o_object IS NOT INITIAL.

CALL METHOD o_object->check_changed_data

endif.

but here it gives a dump at call method.

Regards,

Ritwik

0 Kudos

ok.. then comment the i_grid_settings..

Can you send me your current user command code.

Also.. did you comment the lines in the field catalog i mentioned?

0 Kudos

Hi Suzie,

of course ... the code is as follows.

FORM user_command USING ucomm LIKE sy-ucomm

selfield TYPE slis_selfield.

DATA: lv_ucomm TYPE sy-ucomm.

lv_ucomm = ucomm.

DATA: o_object TYPE REF TO cl_gui_alv_grid.

CASE lv_ucomm.

WHEN '&APPROVE'.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

e_grid = o_object.

IF o_object IS NOT INITIAL.

CALL METHOD o_object->check_changed_data.

ENDIF.

LOOP AT it_zfi_db_cr INTO wa_zfi_db_cr WHERE chk = 'X'.

**BDC code**

WHEN '&REJECT'.

LOOP AT it_zfi_db_cr INTO wa_zfi_db_cr WHERE chk = 'X'.

IF wa_zfi_db_cr IS NOT INITIAL.

wa_zfi_db_cr2-mandt = sy-mandt.

wa_zfi_db_cr2-referenceno = wa_zfi_db_cr-referenceno.

wa_zfi_db_cr2-documentdt = wa_zfi_db_cr-documentdt.

wa_zfi_db_cr2-customercode = wa_zfi_db_cr-customercode.

wa_zfi_db_cr2-vendorcode = wa_zfi_db_cr-vendorcode.

wa_zfi_db_cr2-cust_desc = wa_zfi_db_cr-cust_desc.

wa_zfi_db_cr2-vend_desc = wa_zfi_db_cr-vend_desc.

wa_zfi_db_cr2-reason_code = wa_zfi_db_cr-reason_code.

wa_zfi_db_cr2-reason_desc = wa_zfi_db_cr-reason_desc.

wa_zfi_db_cr2-amt_posted = wa_zfi_db_cr-amt_posted.

wa_zfi_db_cr2-currency = wa_zfi_db_cr-currency.

wa_zfi_db_cr2-text = wa_zfi_db_cr-text.

wa_zfi_db_cr2-creator_id = wa_zfi_db_cr-creator_id.

wa_zfi_db_cr2-dt_of_create = wa_zfi_db_cr-dt_of_create.

wa_zfi_db_cr2-release_id = wa_zfi_db_cr-release_id.

wa_zfi_db_cr2-dt_of_release = wa_zfi_db_cr-dt_of_release.

wa_zfi_db_cr2-released = wa_zfi_db_cr-released.

wa_zfi_db_cr2-rejected = 'Yes'.

wa_zfi_db_cr-rejected = 'Yes'.

wa_zfi_db_cr2-rel_doc_num = wa_zfi_db_cr-rel_doc_num.

wa_zfi_db_cr2-sap_uid = wa_zfi_db_cr-sap_uid.

wa_zfi_db_cr2-posting_date = wa_zfi_db_cr-posting_date.

wa_zfi_db_cr2-entry_date = wa_zfi_db_cr-entry_date.

MODIFY zfi_db_cr FROM wa_zfi_db_cr2. "INDEX sy-tabix.

MODIFY it_zfi_db_cr FROM wa_zfi_db_cr.

COMMIT WORK.

CLEAR wa_zfi_db_cr.

CLEAR wa_zfi_db_cr2.

ENDIF.

ENDLOOP.

PERFORM display_data.

WHEN '&REF'.

CLEAR it_zfi_db_cr.

REFRESH it_zfi_db_cr.

PERFORM fetch_data.

CLEAR it_fieldcat.

REFRESH it_fieldcat.

PERFORM build_fieldcat.

PERFORM build_layout.

PERFORM display_data.

ENDCASE.

ENDFORM. "user_command

Yes ... i have commented the code as u suggested. Please let me know in case of any other queries.

Regards,

Ritwik

Edited by: Ritwik Rajkumar on Jul 12, 2011 1:26 PM

0 Kudos

Ok.. this really is perplexing..

can you create a new program with the following code in your system and see if it runs.. If it does, you can compare with your program.

DATA: BEGIN OF itab OCCURS 0,

matnr TYPE mara-matnr,

ersda TYPE mara-ersda,

ernam TYPE mara-ernam,

laeda TYPE mara-laeda,

aenam TYPE mara-aenam,

matkl TYPE mara-matkl,

sel TYPE char01,

END OF itab.

DATA it_field TYPE slis_t_fieldcat_alv.

DATA wa TYPE slis_fieldcat_alv.

SELECT matnr

ersda ernam

laeda aenam

matkl UP TO 10 ROWS FROM mara INTO TABLE itab.

CLEAR wa.

wa-fieldname = 'MATNR'.

APPEND wa TO it_field.

CLEAR wa.

wa-fieldname = 'ERSDA'.

APPEND wa TO it_field.

CLEAR wa.

wa-fieldname = 'ERNAM'.

APPEND wa TO it_field.

CLEAR wa.

wa-fieldname = 'LAEDA'.

APPEND wa TO it_field.

CLEAR wa.

wa-fieldname = 'AENAM'.

APPEND wa TO it_field.

CLEAR wa.

wa-fieldname = 'MATKL'.

APPEND wa TO it_field.

CLEAR wa.

wa-fieldname = 'SEL'.

wa-checkbox = 'X'.

wa-edit = 'X'.

APPEND wa TO it_field.

CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'

EXPORTING

i_callback_program = sy-repid

i_callback_user_command = 'USER'

it_fieldcat = it_field

TABLES

t_outtab = itab.

&----


*& Form user_command

&----


  • text

----


  • -->UCOMM text

  • -->SELFIELD text

----


FORM user USING ucomm LIKE sy-ucomm

selfield TYPE slis_selfield.

DATA: lv_ucomm TYPE sy-ucomm.

lv_ucomm = ucomm.

DATA: o_object TYPE REF TO cl_gui_alv_grid.

  • CASE lv_ucomm.

  • WHEN '&APPROVE'.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

e_grid = o_object.

IF o_object IS NOT INITIAL.

CALL METHOD o_object->check_changed_data.

ENDIF.

BREAK-POINT.

endform.

0 Kudos

Hi Suzie,

I think it worked. It was my mistake. There was a difference between the name of the field for the checkbox in the internal table and the one defined in the field catalog.

I observed that when u gave that code reference above.

Thanks a ton!!!

I am awarding you full points for all your help and your patience with me.

Regards,

Ritwik

Edited by: Ritwik Rajkumar on Jul 12, 2011 3:55 PM

0 Kudos

I guessed it would be something with the names assigned. tats y I gave the ref code..

I have had to face several dumps coz of field catalog errors too.. And its really confusing to pin point the error as it simply would say the field-symbol is not assigned.

Anyways glad i could help.

0 Kudos

Ritwik,

I had the same requirement, and was not getting the selected lines in the internal table, in the check-boxes.

But this solution you provided works just perfectly.

CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'

IMPORTING

e_grid = o_object.

CALL METHOD o_object->check_changed_data.

Thank you.

0 Kudos

thank u suzie.

u your code is very helpful...

0 Kudos

I am glad it worked for you Fabio.

Former Member
0 Kudos

hello,

add single value type C and length 1 to your fieldcatalog and set ls_fcat-checkbox = 'X'.

ls_fcat-fieldname = 'ZCHECK' .
  ls_fcat-coltext   = 'Select'.
  ls_fcat-seltext   = 'Select'.
  ls_fcat-checkbox  = 'X'.
  ls_fcat-outputlen = 1.
  LS_FCAT-edit      = 'X'.
  insert ls_fcat into pt_fieldcat index 1.

or if you use FM to define your fieldcatalog then:

call function 'LVC_FIELDCATALOG_MERGE'
    exporting
      i_structure_name       = 'STRUCTURE NAME'
    changing
      ct_fieldcat            = pt_fieldcat[]
    exceptions
      inconsistent_interface = 1
      program_error          = 2
      others                 = 3.

ls_fcat-checkbox  = 'X'.
 modify pt_fieldcat  from ls_fcat transporting checkbox where fieldname = 'ZCHECK'.

and before looping through internal table insert this part of code:

call method gv_alvgrid->check_changed_data.

selected lines will be with filled ZCHECK field.

br,

dez_

Former Member
0 Kudos

Hi,

I had similar requirement in a non-OO report, I used following approach:

Inside the user_command perform:

 DATA: ref_grid TYPE REF TO cl_gui_alv_grid 

CASE sy-ucomm.
    WHEN 'Some_command'.
* to reflect the data changed into internal table
      IF ref_grid IS INITIAL.
        CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
          IMPORTING
            e_grid = ref_grid.
      ENDIF.

      IF NOT ref_grid IS INITIAL.
        CALL METHOD ref_grid->check_changed_data.
      ENDIF.

      LOOP AT i_alvtable  INTO work_area  WHERE check_box = c_x.
    

    ENDLOOP.

Hope it helps.

Former Member
0 Kudos

Hello Ritwik,

Try using the below method

data_changed_finished - in method's implementation update the internal table with checkbox value.

Hope this may be helpful.

Regards,

Sharin.