Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Trying to adapt a Standard Web Dynpro Component

Hi,

I want to change the 'Caption_1' of the WDC EHHSS_INC_ROOT_CAUSE from 'Root Causes' to 'Causal Factors'. What I did is that I have created a component configuration and made all the changes there but after this is done I don't see the changes. Please see the screen-shot. Can you help in getting this fixed. Thanks.

replied

Hi,

I used a pre-exit to dynamically change the captions -

CONSTANTS:  lc_cafas TYPE wdy_md_translatable_text VALUE 'Casual Factors',           

                         lc_cafa  TYPE wdy_md_translatable_text VALUE 'Casual Factor'. 

DATA: lo_wd_caption TYPE REF TO cl_wd_caption.

  IF first_time = abap_true.   

    lo_wd_caption ?= view->get_element( id = 'CAPTION_1' ).   

    lo_wd_caption->set_text( value = lc_cafas  ).   

    lo_wd_caption ?= view->get_element( id = 'CAPTION_3' ).   

    lo_wd_caption->set_text( value = lc_cafa  ).   

    lo_wd_caption ?= view->get_element( id = 'CAPTION_6' ).    .

    lo_wd_caption->set_text( value = lc_cafas  ). 

  ENDIF.

Thanks & Closing the thread

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question