cancel
Showing results for 
Search instead for 
Did you mean: 

Configuration at runtime..DLC_CONFIG_ACCESS_BADI or DO_CONFIG_DETERM ??

Former Member
0 Kudos
108

Hi experts!!

What i would like is to change the configuration of the Account Details screen at runtime, based on certain conditions.

I read about DO_CONFIG_DETERMINATION method but i don't understand how to use it since i cannot give Role Configuration Key.

I also read about BADI DLC_CONFIG_ACCESS_BADI where in the exprting parameters i can pass context id, role configuration key etc..I tried it but i get different exceptions at runtime..

Anyone used any of those two successfully?

Any sample code maybe????

Thank you all in advance

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Leon!

But for both configurations object type is 'BP_ACCOUNT' and object subtype 'INDIVIDUAL'...

What should i change???

0 Kudos

Hi Grigoria,

You should maintain different Role Configuration Key for both the configurations.

The Role Configuration Key will be automatically taken from the logged in business role of the user.

Regards,

Leon

Edited by: Leon Limson on Feb 13, 2012 5:44 PM

Former Member
0 Kudos

Hi Leon & thank you for your help!!

I created different object types in customizing and attached subtypes using interface implementation IF_BSP_DLC_OBJ_TYPE_CALLBACK~GET_OBJECT_SUB_TYPES for callback classes.

I written the code in DO_CONFIG_DETERMINATION, but still <DEFAULT> configuration is returned.I debugged the code after DO_CONFIG_DETERMINATION and looks like my configuration is invalid.

But it was a copy of <DEFAULT>.. Any ideas???

Thank you!!!

0 Kudos

Hi Grigoria,

What is the Role Configuration Key maintained in the copied configuration?

If this config is specific for a business role, then maintain the business role in the Role Configuration Key.

Regards,

Leon

Former Member
0 Kudos

Hi Leon!!!

You were right about the configuration key.

Thank you for all your help!!!

Answers (1)

Answers (1)

0 Kudos

Hi Grigoria,

You don't need to implement the BADI. Also you don't need to pass the context id.

You need to pass only the object type, and subobject type using the following code.

me->set_config_keys( iv_object_type          = lv_object_type
                       iv_object_sub_type      = lv_subtype
                       iv_propagate_2_children = abap_true).

Regards,

Leon