on 05-09-2011 12:00 PM
Hi Experts,
I'm developing a WebDynpro where the user can convert its output into PDF and display/download it. The Converting Process is started via a button. Once the user klicks the button, there's quite a lot of stuff happening in the background, It'll take about 10-15secs. I'm afraid that some users might start hammering on F5 once nothing appears on screen after 3 secs or so, thus I want to display a message "Please Wait until..." etc once the user clicks on that button. I thought I could just do that at the beginning of my Event Handler of the Button. But the message is displayed as recently as the complete method has run through...
How can I immediately display a message once a user klicks on that button?
best regards,
Lukas
Hi,
You can write your message handling code before your actual code, i.e. at starting, first it will execute and display message.
OR
You better display popup confirmation message saying that "Please wait 15 Sec.. Processing" Like that.
Check Below code..
data lo_window_manager type ref to if_wd_window_manager.
data lo_api_component type ref to if_wd_component.
data lo_window type ref to if_wd_window.
data lo_view_controller type ref to if_wd_view_controller.
data : lt_text TYPE string_table,
ls_text TYPE string.
ls_text = ' Please WAit 15 Sec...Processing..'.
INSERT ls_text INTO TABLE lt_text.
Get Window manager
lo_api_component = wd_comp_controller->wd_get_api( ).
lo_window_manager = lo_api_component->get_window_manager( ).
lo_window = lo_window_manager->create_popup_to_confirm( text = lt_text
button_kind = if_wd_window=>CO_BUTTONS_OK
message_type = if_wd_window=>CO_MSG_TYPE_WARNING
window_title = 'Information to Confirm...'
window_position = if_wd_window=>co_center ).
lo_view_controller = wd_this->wd_get_api( ).
creating ok button
lo_window->subscribe_to_button_event(
button = if_wd_window=>co_button_ok
action_name = 'OK' // Createonce action of name OK.
action_view = lo_view_controller
is_default_button = abap_false ).
Set the height and width here
lo_window->set_window_size( width = '40%' height = '5%' ).
lo_window->open( ).
Cheers,
Kris.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.