Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Closing popup in web dynpro


i am new to web dynpro , can somebody tell hoe can i close a custom popup from a close button which is available in the same popup.

Thanks in advance




Hi John,

Create an attribute for the popup window under attributes tab with the type of IF_WD_WINDOW in the desired View.

Then open the popup window with the following code ,

    wd_comp_controller->popup_window  = lo_window_manager->create_window(

                        window_name            = 'W_APP_REJ_POPUP'

                        title                  = 'CAS Approval'

                        close_in_any_case      = abap_false

                        message_display_mode   = if_wd_window=>co_msg_display_mode_selected

                        close_button           = abap_true

                        button_kind            = if_wd_window=>co_buttons_yesno

                        message_type           = if_wd_window=>co_msg_type_none

                        default_button         = if_wd_window=>co_button_yes ).

For closing the popup call this code from the close button:

wd_comp_controller->popup_window->close( ).

- Gowtham

1 View this answer in context

Helpful Answer

Not what you were looking for? View more on this topic or Ask a question