Skip to Content

WDDOEXIT ignoring POPUP window?

Hi experts,

I am trying to display a popup window during wddoexit (of the component controller) to ask the user if they want to leave the application. I am using

if_window_manager->create_popup_to_confirm() and lo_window->open( ) to do so but the open command is being ignored and the app is ending without displaying the popup window. Not sure if I am missing anything or if it is just too late to this in wddoexit?

Any advise?

Thanks,

Wolfgang

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Apr 25, 2014 at 05:44 PM

    Hi,

    I tried the following in the same method of window and it is working fine for me. But in my example, I tried inside another window which is getting called from Handle default event from Main window.

    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 lt_text TYPE string_table.

      DATA ls_text LIKE LINE OF lt_text.

      ls_text = 'test'.

      APPEND ls_text TO lt_text.

      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          = 1 ).





      lo_window->open( ).

    Add comment
    10|10000 characters needed characters exceeded

  • Apr 25, 2014 at 06:26 PM

    Hi,

    I am trying to display a popup window during wddoexit (of the component controller) to ask the user if they want to leave the application.

    You cannot do that to stop the application from closing/navigating. By the time the WDDOEXIT fires, it's too late to trigger any events that stops closing the browser.

    The possible way is, If you are using your WDA application in portal, use portal work protect mode. If you are using it as stand alone, Use FPM and implement the IF_FPM_WORK_PROTECTION to use work protect mode.

    hope this helps u,

    Regards,

    Kiran

    Add comment
    10|10000 characters needed characters exceeded