cancel
Showing results for 
Search instead for 
Did you mean: 

Making empty fields invisible

Former Member
0 Kudos

hi,

I am having a no of text views in which data is coming from data base. Now my requirement is if there is no value in text view then it should nt be visible.

plz suggest hw can i proceed.

i can nt bind every UI with attribute and control its visibility independently. because no of UI are very large.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Pankaj,

I dont see any other alternative

Thanks

Bala Duvvuri

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Pankaj,

I would suggest that you limit the things you do at runtime.

You could define minimum number of text views which you expect and then add more dynamically.

Regards

Anurag Chopra

Former Member
0 Kudos

Yes.

Maybe you can use "CL_WD_TEXT_VIEW" in the "WDMODIFYVIEW" method.

for example:

"1st, you should add all the Text-view UI element into one internal table which has the ID of the UI element.

data: lo_txt_view type ref to CL_WD_TEXT_VIEW.

loop at lt_all_txt_views into ls_txt_view.

lo_txt_view ?= view->get_element( ls_txt_view-ID ).

if the context attribute value binded to the text_view is initial.

lo_txt_view->set_eneable( abap_false ).

endif.

endloop.

Best Wishes.

Former Member
0 Kudos

Hi,

You can use Cl_wd_text_view class and its methods but i dont think it is best solution.