on 04-30-2007 1:01 PM
Hi,
Use method REPORT_ERROR_MESSAGE of interface IF_WD_MESSAGE_MANAGER to create an error message in the webdynpro application.
This works fine, the message is shown in the message area.
Now I want to have the error message in a popup.
In the method REPORT_ERROR_MESSAGE i set the parameter SHOW_AS_POPUP on abap_true but i get no popup.
Is anyone familar with this?
Thanks.
Vincent.
Hi ,
This can be done by ......
wd_this->uom_popup = l_window_manager->create_window(
window_name = 'W_UNIT_OF_ISSUE'
close_in_any_case = ' '
button_kind = if_wd_window=>co_buttons_okcancel
title = title ).
In the above code i am using a statements:: close_in_any_case = ' '
So this will show all the error message in the popup itself no need to declare the message area in the popup.
Hope this'll solve your problem.
Regards,
Satya
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vincent.
That's one I fell into as well. That importing field is not is use yet. Perhaps in a future support stack.
You can bypass that by using the CREATE_POPUP_TO_CONFIRM method. Below, you'll find some code from SAP's documentation. All you need to do is select the button type and create some actions to receive input from the 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. "#EC *
insert `Do you want to save?` into table l_text. "#EC *
l_popup = l_window_manager->create_popup_to_confirm(
text = l_text
button_kind = if_wd_window=>co_buttons_yesnocancel
message_type = if_wd_window=>co_msg_type_question
window_title = 'Test: Popup to confirm'
window_position = if_wd_window=>co_center )."#EC *
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_false ).
l_popup->subscribe_to_button_event(
button = if_wd_window=>co_button_cancel
action_name = 'CANCEL'
action_view = l_api
is_default_button = abap_false ).
l_popup->open( ).
Hope this helps.
Adam
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
82 | |
10 | |
10 | |
9 | |
6 | |
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.