on 04-10-2014 8:26 AM
Hi Experts,
i am using select options in my application.
i have made two block for the selec options (transparent container 1 and transparent container 2) by using add_block method of select option.So i cant do the normal context binding as containers are created programatically.
Now i have a requirement to hide one of the block on click of an event so that the select options inside is also hidden.
DATA lo_ui_element type ref to CL_WD_UIELEMENT.
DATA lo_container TYPE REF TO cl_wd_uielement_container.
DATA lo_transc TYPE REF TO cl_wd_view_element.
" get root container
lo_container ?= view->get_root_element( ).
*" get button reference
lo_transc ?= lo_container->get_child() // Get the tray which container the view container of select options.
then inside this i have the transparent container which has the selec options.
Please help
Tashi
Hi Tashi,
1. Add your Select-Options screen elements(Your blocks) to UI View Container element and bind the context to WDUI_VISIBILITY. Set the visibility depends on your requirement.
2. You have REMOVE_SELECTION_SCREEN_ITEM method from Interface IF_WD_SELECT_OPTIONS to remove the fields at runtime.
Please follow the below link
Creation and Deletion of selection screen elements based on user action
Hope it helps you
BR,
RAM.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Ram,
i need to create two different blocks with single instance of select option.
select-option view is attached to a single view container, i cant declare usage of transparnt containers.
Since the select-options are created dynamically, the grouping also happends dynamically with add_block method(transparent container).Now i need to hide and unnhide one block depending on a action.
i have already tried remove selection screen item method, it works fine but felt its not the right way of doing it.
Regards,
Tashi
User | Count |
---|---|
94 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.