on 03-25-2008 1:50 PM
hi All,
I have placed one Tranparent container with some UI Elements inside.
I want to set the Transparent container's visibility to none in view init method.
And also i want to set the Transparent container's visibility as visible in a button click event.
For that i have created an Attribute 'Visibility' with type WDUI_VISIBILITY.
I want the coding that has to be written in the view init method and in the button click action.
Regards,
Dinesh
hi dinesh ...
DATA lo_el_context TYPE REF TO if_wd_context_element.
DATA ls_context TYPE wd_this->element_context.
DATA lv_string LIKE ls_context-string.
* get element via lead selection
lo_el_context = wd_context->get_element( ).
* get single attribute
lo_el_context->set_attribute(
name = `STRING`
value = '01' ).
string is the name of the attribute that is bound to the viisibility property.
---regards,
alex b justin
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi Justin,
thanks for your reply.
Can you clear me , why we have to write these two lines.
DATA ls_context TYPE wd_this->element_context.
DATA lv_string LIKE ls_context-VISIBILITY.
For testing purpose i have changed the visibility property to '02' in init method. But still the Trasparent container UI element is invisible.
Regards,
Dinesh
Hi Dinesh,
The 2 statements are for data declerations.
ls_context is to hold the reference to the context element and the lv_string for holding the value of the visibility property.
The WDDOINIT method of a given view is triggered only for the first time when the view is rendered. So next if you go back and come in the view again the WDDOINIT is not called.
So if you go back and come into the view, the transparent container is still in the same state as it was.
Regards,
Sravan Varagani
User | Count |
---|---|
83 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.