cancel
Showing results for 
Search instead for 
Did you mean: 

changing default value of attribute in a standard webdynpro component

Former Member
0 Kudos

Hi Experts,

I have a requirement to change the default value ( from '01' to '02' ) for an attribute ( ACC_IND ) in one standard webdynpro component : /SAPSRM/WDC_DODC_SC_I_LIM.

This attribute belongs to 'account assignment' field in limit item which is in shopping cart.

Please let me know if I should provide some more details for you to help/reply me.

thank you

Prasanth

Accepted Solutions (0)

Answers (1)

Answers (1)

vinita_kasliwal
Active Contributor
0 Kudos

Hi Prasanth

Try this in WDDOMODIFY with first_time = ABAP_TRUE .. so it will only run once during the start of the application .,.

or you can put in WDDOINIT

If you want this to be like this always use it without any such condition

DATA: lr_nodeTYPE REF TO if_wd_context_node,
lr_subnode TYPE REF TO if_wd_context_node,
ls_subnode TYPE wd_this->element_limit_sub.

lr_node = wd_context->get_child_node( name = wd_this->wdctx_limit_item ).

lr_subnode = lr_node->get_child_node( name = wd_this->wdctx_limit_sub ).

ls_subnode-acc_ind = '02'.

lr_subnode->set_static_attributes( ls_subnode ).

Regards

Vinita

Include first_time = ABAP_TRUE condition

vinita_kasliwal
Active Contributor
0 Kudos

Did it work for you ?I was expecting an update 😕