on 06-25-2008 12:20 PM
IS there any method that supports to embed the View in the Window at runtime, so that i can use only a single window for the POP ups
Hi Vikranth,
U can use single window for the popup's .
Write this code in the action handler of button for which u want to display popup.
data: l_cmp_api type ref to if_wd_component,
l_window_manager type ref to if_wd_window_manager,
l_popup type ref to if_wd_window.
l_text type string_table,
l_api type ref to if_wd_view_controller.
l_cmp_api = wd_comp_controller->wd_get_api( ).
l_window_manager = l_cmp_api->get_window_manager( ).
insert `Data where changed` into table l_text.
insert `Do you want to save?` into table l_text.
l_popup = l_window_manager->create_popup_to_confirm(
text = l_text
button_kind = 5
message_type = message_type = if_wd_window=>co_msg_type_question
window_title = 'Test: Popup to confirm'
window_position = if_wd_window=>co_center ).
l_api = wd_this->wd_get_api( ).
l_popup->subscribe_to_button_event(
button = if_wd_window=>co_button_yes
action_name = 'YES'
action_view = l_api
is_default_button = abap_true ).
l_popup->subscribe_to_button_event(
button = if_wd_window=>co_button_no
action_name = 'NO'
action_view = l_api
is_default_button = abap_true ).
l_popup->subscribe_to_button_event(
button = if_wd_window=>co_button_cancel
action_name = 'CANCEL'
action_view = l_api
is_default_button = abap_true ).
l_popup->open( ).
In this subscribe_to_button_event method is used for handling the actions of popup buttons.
and for this method write the action names YES,NO CANCEL in the actions tab of your view.
Reward points if useful..............
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
See these: [https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/2888] [original link is broken] [original link is broken] [original link is broken];
[https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/2915] [original link is broken] [original link is broken] [original link is broken];
[https://www.sdn.sap.com/irj/sdn/weblogs?blog=/pub/wlg/2953] [original link is broken] [original link is broken] [original link is broken];
Regards.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
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.