If you have implemented an ABAP web dynpro iView into your portal you may want to have an back button which leaves your created web dynpro
and returns to the portal page it was called from. See here for creating ABAP web dynpro button.
Once you have created a button on your web dynpro you need to add the following code to the button action method in order to return to the previous page of your portal.
Step 1
Within the button action method or wherever you want to call the previous portal page add the following code:
data: lr_compcontroller type ref to ig_componentcontroller, l_component type ref to if_wd_component. data lr_port_manager type ref to if_wd_portal_integration. lr_compcontroller = wd_this->get_componentcontroller_ctr( ). l_component = lr_compcontroller->wd_get_api( ). lr_port_manager = l_component->get_portal_manager( ). CALL METHOD lr_port_manager->fire EXPORTING portal_event_namespace = 'urn:com.sapportals:navigation' portal_event_name = 'historyNavigate' portal_event_parameter = '-1' . |