cancel
Showing results for 
Search instead for 
Did you mean: 

How to close pop up and open new window?

Former Member
0 Kudos

Hi experts,

I have created popup window for user login . and embeded a view which accept user name and pwd also contains a submit button.

  in submit method action handler i am verifying user and then opening interface view of another component.

  Till verification i able to do but  i am not geting how to close the pop up window and open the window of interface view.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi vishal for ur requirement u hav to  subscribe a button for opning a new window ..

for opening a new window u hav to go for create external window..

i think this will be usefull..

Thanks And Regards ..

Lokesh

chengalarayulu
Active Contributor
0 Kudos

Hi Vishal,

1. wherever you are opening popup window, there do assign the window reference means, let create a IF_WD_WINDOW reference at Component Controller/Assistance class level and assign the popup window reference like below.

eg. wd_comp_controller->lr_window = lo_window.

2. on Logon popup in Submit action just use close method like below.

     wd_comp_controller->lr_window->close( ).

3. now you can navigate to required window/view.

thanks.

Former Member
0 Kudos

if i close the window then how the interface view of another component will display?

chengalarayulu
Active Contributor
0 Kudos

Check the below code:

   lo_api_component  = wd_comp_controller->wd_get_api( ).

   lo_window_manager = lo_api_component->get_window_manager( ).

   lo_window         = lo_window_manager->create_window_for_cmp_usage(

   interface_view_name    = 'W_EXISTING_ASSIGNMNT'

   component_usage_name   = 'ITEM_ASSIGNMENT'

   title                  = lv_text_101

   close_in_any_case      = abap_true

   message_display_mode   = if_wd_window=>co_msg_display_mode_selected

    ).

Lo_window->open.

Former Member
0 Kudos

This is working but new window should open as new web page but it is only showing window

chengalarayulu
Active Contributor
0 Kudos

Hi Vishal,

Try to open as external window, then you can feel better.