Skip to Content

SAP UI5 View Navigation not working

Jul 20, 2017 at 02:29 PM


avatar image

Hello Experts,

My requirement is to navigate from one view(master) to another view(detail) using Web IDE, but navigation is not working, Master view is displayed with Button as expected, but when i click on it, it should go to detail view which is not working, I don't see any errors other than "Failed to load resource: the server responded with a status of 404 (Not Found)", please help, here is code.

App View:

<App id="app"/>

View1 View:


<pages> <Page title="{i18n>title}">

<content> <Button text='Next' press="handleListItemPress"></Button>





Detail View:

<Page title="Title" showNavButton="true" navButtonPress="handleNavButtonPress"> <content>

<Text text="This is Detail Page"/>



Root View: App

"sap.ui5": { "rootView": { "viewName": "HelloWorld.view.App", "type": "XML" },


return Controller.extend("HelloWorld.controller.View1", {

handleListItemPress: function(evt) { var oRouter = sap.ui.core.UIComponent.getRouterFor(this); oRouter.navTo("detail"); }


capture.png (28.3 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
saurabh vakil Jul 20, 2017 at 04:44 PM

The "detail" route in the routes array has the pattern blank (""), it should be "pattern": "detail" instead.

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


It's working with that, Thank you!