Application Development and Automation 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: 
Read only

Read column index

Former Member
0 Likes
1,187

Hi Experts,

Is it possible to read the column index in 'cl_gui_alv_grid'

BR,

King

1 ACCEPTED SOLUTION
Read only

nabheetscn
SAP Champion
SAP Champion
0 Likes
1,146

Hi King

What exactly do you intend to do?

Nabheet

Hi Experts,

Is it possible to read the column index in 'cl_gui_alv_grid'

BR,

King

6 REPLIES 6
Read only

nabheetscn
SAP Champion
SAP Champion
0 Likes
1,147

Hi King

What exactly do you intend to do?

Nabheet

Read only

0 Likes
1,146

Hi Nabheet,

I created an alv using grid->set_table_for_first_display.

I also had method as below:

     handle_double_click

           FOR EVENT double_click OF cl_gui_alv_grid IMPORTING e_row,

I can obtain the row index by e_row.

Is it possible to read the column index also?

BR

King

Read only

0 Likes
1,146

Use parameter e_column to get column name.

handle_double_click

           FOR EVENT double_click OF cl_gui_alv_grid IMPORTING e_row

                                                                                                            e_column,

Regards

Read only

0 Likes
1,146

Thanks!

May I ask how to view the import parameter in method?

Thus, I can check by myself later.

BR,

King

Read only

0 Likes
1,146

Hi,

Go to SE24 and enter the class name. Then go to events tab and place the cursor on your desired event and click on "parameters" button.

Regards

Read only

Former Member
0 Likes
1,146

Hi,

In the event Double click they are three parameters

so you can use E_column to get the column name