on 04-03-2008 11:40 AM
Is it possible to set aggregation rules and group aggregation rules for a table, the same way it is done for an alv with the following code?
If so, how is it done?
Thank you in advance.
lo_value->IF_SALV_WD_STD_FUNCTIONS~SET_GROUP_AGGREGATION_ALLOWED( ).
lo_value->IF_SALV_WD_STD_FUNCTIONS~SET_AGGREGATION_ALLOWED( ).
data: lr_field_settings type ref to if_salv_wd_field_settings,
lr_field type ref to cl_salv_wd_field,
lr_aggr_rule type ref to cl_salv_wd_aggr_rule.
lr_field_settings ?= lo_value.
lr_field_settings->set_group_aggr_displayed( abap_true ).
lr_field_settings->set_aggr_before_items( abap_true ).
lr_field = lr_field_settings->get_field( 'FIELD1' ).
lr_field->if_salv_wd_aggr~create_aggr_rule( ).
lr_aggr_rule = lr_field->if_salv_wd_aggr~get_aggr_rule( ).
lr_aggr_rule->set_aggregation_type( if_salv_wd_c_aggregation=>aggrtype_total ).
lr_field = lr_field_settings->get_field( 'FIELD2' ).
lr_field->if_salv_wd_aggr~create_aggr_rule( ).
lr_aggr_rule = lr_field->if_salv_wd_aggr~get_aggr_rule( ).
lr_aggr_rule->set_aggregation_type( if_salv_wd_c_aggregation=>aggrtype_total ).
Hi ,
U can use the summary cell....... see the below link..
http://help.sap.com/saphelp_nw70/helpdata/en/b5/ac884118aa1709e10000000a155106/frameset.htm
Regards
Yash
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
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.