cancel
Showing results for 
Search instead for 
Did you mean: 

position of columns in a table

Former Member
0 Kudos

Hello,

please help me on how to set the position of columns for a table not for a alv-table at a runtime via coding.

How can we change the positions in ABAP?

Regards

Beserithan

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

Actually you can get the reference of that column and in the column class there is this method to set the position. It worked for me.. hope it will for u 2.

Tenzin

Former Member
0 Kudos

Hi,

I don't see any partcular method in cl_wd_table_column class for setting column position ( in ALV for class cl_salv_wd_column we have one method for this set_postion ).

What you can do probably as a workaround is to remove all columns (remove_all_columns of cl_wd_table ) nad then add columns again in code ( new_table_column method of class cl_wd_table_column and then using add_column of cl_wd_table) in whatever order you want.

Let's see if others can come up with some straightforward solution.

Regards

Manas Dua

Edited by: Manas Dua on Apr 9, 2010 7:24 PM

Edited by: Manas Dua on Apr 9, 2010 7:53 PM

Former Member
0 Kudos

Hello Manas,

many thanks for your reply. As you mentioned, i did not find any method for setting the position in a table.

But your suggestion is a good workaround. I will try it.

Regards

Beserithan