cancel
Showing results for 
Search instead for 
Did you mean: 

How to open a app in new window in Cross Application Navigation in FLP?

Jayakrishnan
Active Participant

Hi All,

I have Application 1 and Application 2 in my Fiori Launchpad. I have done the Cross application navigation from Application 1 to Application 2. It requires some routing parameters for the navigation,

When i click back (both FLP back icon and Browser icon), it goes to Application 1.

But i want Application 2 should open on new tab in the browser. Not inside the FLP. So that i can compare both Application in the same time. How do i achieve this?

Thank you,

Regards,

JK.

Accepted Solutions (0)

Answers (1)

Answers (1)

maheshpalavalli
Active Contributor
0 Kudos

Hi Jayakrishnan Chandramohan,

You can try this below

var sHash = sap.ushell.Container.getService('CrossApplicationNavigation').hrefForExternal({
  target: {
       semanticObject : 'semobj', 
       action: 'action'
  }
});
sap.m.URLHelper.redirect(window.location.href.split('#')[0] + sHash, true);

BR,

Mahesh

Jayakrishnan
Active Participant
0 Kudos

Hi Mahesh,

Thank you for your comments.

I read this, but i got some documentation link, saying we could not use window.location. is that not good practices?

https://help.sap.com/doc/saphelp_nw751abap/7.51.0/en-US/3a/35ab684174415899c98da4931bd6c1/content.ht...

maheshpalavalli
Active Contributor
0 Kudos

Hi Jayakrishnan Chandramohan,

You are right, for changing the hash you shouldn't use it. But if you see we are still not using the window.location.hash to change the hash, but we are using some hybrid kind of thing.

If you see the code, I am determining the URL without the hash and determining the hash using the crossappnavigation api. Why I am using window.location.href is as I was not able to find the way to determine the url (I tried to check the same API, but couldn't find a method which does that).

BR,

Mahesh