cancel
Showing results for 
Search instead for 
Did you mean: 

creaion of dynamic textview

Former Member
0 Kudos

Hi all,

i want to create a dynamic textview in my layout.

can you please tell me how can i achieve it.

please explain with code im new to this.

u r inputs will be highly helpful for me.

Thanks and Regards,

santosh

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

WDDOMODIFYVIEW is used for dynamic programming and any other screen manipulations. Place the following code in WDDOMODIFYVIEW.

DATA: l_root_cnt TYPE REF TO cl_wd_uielement_container,
l_text_view TYPE REF TO cl_wd_text_view,
l_flow_data TYPE REF TO cl_wd_flow_data.

* Check whether the method is called for the first time
IF first_time = abap_true.

* Get the reference of ROOTUIELEMENTCONTAINER
l_root_cnt ?= view->get_element( 'ROOTUIELEMENTCONTAINER' ).

* Create Text View
l_text_view = cl_wd_text_view=>new_text_view( id = 'TEXTVIEW1' " unique id
text = 'This is dynamically created Text View' ). " your text

* Layout 
l_flow_data = cl_wd_flow_data=>new_flow_data( element = l_text_view ).

l_root_cnt->add_child( l_text_view ).

ENDIF.
Radhika.

former_member40425
Contributor
0 Kudos

Check sample web dynpro component 'DEMODYNAMIC' in package SWDP_DEMO.

Check[ class CL_WD_DYNAMIC_TOOL:|

http://help.sap.com/saphelp_nw70ehp1/helpdata/en/67/6935425394033be10000000a1550b0/frameset.htm];

Regards,

Rohit

Former Member
0 Kudos

Hi,

Check with the following link

[Dynamic text view|http://help.sap.com/saphelp_nw70/helpdata/en/9d/a6884121a41c09e10000000a155106/content.htm]

Hope this helps you.

Regards,

Rajani

Former Member
0 Kudos

Hi,

Please refer to these links -

Please search SCN on the same as there are many thread related to this before you post.

Regards,

Lekha.