cancel
Showing results for 
Search instead for 
Did you mean: 

Navigating Window1 to Window2

former_member205842
Participant
0 Kudos

Hi Experts,

                 I have requirement that i have a component with view1 in Window1 and view2 in Window2, my req is i want to call second view2 of window2 in first view1. Please help to solve this req

Regards

Syed

Accepted Solutions (0)

Answers (6)

Answers (6)

Former Member
0 Kudos

Hi,

You can achieve this in two ways.

1. Navigation using plugs :

  •     create a outbound plug for view1.
  • create a inbound plug for window2
  • Fire view1 outbound plug on your respective method so that you can navigate to view2 from view1.


2. Using Webdynproapplication :

  • create 2 webdynpro applications for your component.
  • one application having window1 has default window.
  • Second applicaiton having window2 has default window.
  • Now to navigate to second view from first view, use code

cl_wd_utilities=>construct_wd_url(

   EXPORTING

     application_name                 = ' ' " Pass Second webdynpro application name

     IMPORTING

       out_absolute_url              = lv_url    ).

lv_url is Second Webdynrpo application URL.

   lo_window_manager = wd_comp_controller->wd_get_api( )->get_window_manager( ).

   lo_window         = lo_window_manager->create_external_window( url = lv_url  ).

   lo_window->open( ).

Regards,
Ravikiran.K

Former Member
0 Kudos

Hi,

  •   One possible way is create 2 windows namely WA,WB.
  •   Two views namely VIEWA VIEWB.
  •   Embed VIEW A in WA and VIEWB in WB.

   Suppose u want to open second WB from WA the following code will work

DATA:  lr_view               TYPE REF TO if_wd_view_controller,

        lr_api_main           TYPE REF TO if_wd_component,

        lr_window_man         TYPE REF TO if_wd_window_manager.

        l_window2        type REF TO IF_WD_WI

lr_view = wd_this->wd_get_api( ).

  lr_api_main = wd_comp_controller->wd_get_api( ).

  lr_window_man = lr_api_main->get_window_manager( ).

*Creating the Popup Window

  CALL METHOD lr_window_man->create_window

    EXPORTING

      modal        = abap_true

      window_name  = 'WB'

      title        = 'Demo example'

      close_button = abap_true

    RECEIVING

      window       = wd_comp_controller->l_window2.

    wd_comp_controller->l_window2->open( ).

ronaldo_aparecido
Contributor
0 Kudos

Hi worked ?

former_member205842
Participant
0 Kudos

HI Ronaldo,

                 I used to call second window view in first window using ViewUIElement

kmoore007
Active Contributor
0 Kudos

You might want to go through these e-learnings from Thomas Jung:

ronaldo_aparecido
Contributor
0 Kudos

Please See this link.

Thanks

former_member184741
Active Contributor
0 Kudos

hi,

Please read some basic webdynpro tutorials before posting a question. It will save your time and others.