Skip to Content
0

CrossApplicationNavigation - Code not working , No Error on Console as well.

Jan 02, 2017 at 08:22 AM

134

avatar image
Former Member

Hello,

I am trying my hands on Cross Application Navigation using Semantic Object Navigation. As mentioned in SAP library, I have loaded the following library in index.html for CrossApplicationService

https://sapui5.netweaver.ondemand.com/docs/api/symbols/sap.ushell.services.CrossApplicationNavigation.html

I have written this piece of code for navigation on button click from App 1 to App 2.

This code is not working in the app, and it is not navigating to App 2 ( and also throwing no error in Console ). However, when I test this code in console, it is successfully navigating to second app. Is there anything I am missing. Kindly help :)

Thanks in advance!

1-tmp.png (12.2 kB)
2-tmp.png (20.2 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

6 Answers

Jun Wu Jan 02, 2017 at 02:00 PM
0

did u run your app from launchpad? if not, i will not work.

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Jan 03, 2017 at 07:39 AM
0

Hi Jun

Yes I have run the app from FLP itself.

Regards

Parth

Share
10 |10000 characters needed characters left characters exceeded
Simon Perstorfer Jan 03, 2017 at 09:12 AM
0

Hey,

the following code works fine for me.

var oCrossAppNav = sap.ushell.Container.getService("CrossApplicationNavigation");
			
oCrossAppNav.toExternal({
	target: {
		semanticObject: "<your_semantic_object",
		action: "display"
	}
});

btw: By including a UI5 in the Fiori Launchpad, the index.html will not be loaded. The Launchpad calls the apps component and from there, the app will be started.

Share
10 |10000 characters needed characters left characters exceeded
Simon Perstorfer Jan 03, 2017 at 09:14 AM
0

Hey,

the following code works fine for me.

var oCrossAppNav = sap.ushell.Container.getService("CrossApplicationNavigation");
			
oCrossAppNav.toExternal({
	target: {
		semanticObject: "<your_semantic_object",
		action: "display"
	}
})

btw: If you start your app over fiori launchpad, the index.html will not be executed. The FLP loads the component of you app and from there, the app will be started.

Share
10 |10000 characters needed characters left characters exceeded
Simon Perstorfer Jan 03, 2017 at 09:26 AM
0

Hey,

the following code works fine for me.

var oCrossAppNav = sap.ushell.Container.getService("CrossApplicationNavigation");
			
oCrossAppNav.toExternal({
	target: {
		semanticObject: "<your_semantic_object",
		action: "display"
	}
})

btw: If you start your app over fiori launchpad, the index.html will not be executed. The FLP loads the component of you app and from there, the app will be started.

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Jan 03, 2017 at 10:03 AM
0

Hi Simon,

Thanks for your prompt reply. I had also tried the code earlier that you just sent me. It is not working for me :/ However same code is working fine when tested in console. Could you please share your project code and your LPD Cust params for the UI5 app that you have deployed. May be I am missing something.

Cheers

Parth

Show 1 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi Parth,

Iam facing the same issue. please let me know how did you resolve this probelm.

Thanks in advance

Regards,
Sarath

0