on 03-13-2008 9:38 AM
Hi All
I got sort functionality to the table successfully by adding following code....
But I am facing one problem here i.e. I like to read sort column name
To get sort functionality I added following logic in WDDOMODIFYVIEW method.
DATA wd_table TYPE REF TO cl_wd_table.
CHECK first_time = abap_true.
wd_table ?= view->get_element( 'TABLE_NAME' ).
wd_this->table_control ?= wd_table->_method_handler.
wd_this->table_control->set_key_attribute_name( 'COL_NAME1' ).
here I hard coded first column name(i.e. COL_NAME1). Is it correct?
and added following code in SORT ACTION of table i.e.
wd_this->table_control->apply_sorting( ).
To get column name I am using the method GET_KEY_ATTRIBUTE_NAME of IF_WD_TABLE_METHOD_HNDL in SORT ACTION of table but always I am getting COL_NAME1 only....
Please help me how can I rectify this...
Thank you
Rama
Hi Rama,
One of the import parameters in the ON SORT event handler is COL, This holds the name of the colum on which user hads clicked on for sorting.
Hope this is what you want.
Regards,
Sravan Varagani
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.