Sunday, January 1, 2017

how to hide an ui element in web dynpro

Declare one Attribute in Context node(under CONTEXT tab of view or CONTEXT tab of COMPONENT CONTROLLER) which is of type WDUI_VISIBILITY.
Now bind the above declared attribute with the VALUE property of your UI element(Which element you want to hide).

Now By using CODE wizard ... select the SET radio button and then choose the attribute which is created in Context node...it will generate some predefined code which is shown below.

For Ex:
node->set_attribute(
------
value = lv_attribute
).



Visibility Criteria:


If you want to hide the UI element use
lv_attribute = 01.  (value for hiding)


If you want to show the UI element use
lv_attribute = 02. (value to show UI element) .

You can use this procedure based on button clicks; Like, On click of BUTTON you can display some text elements or I/O fields etc....

1 comment: