Technology Blogs by Members
Explore a vibrant mix of technical expertise, industry insights, and tech buzz in member blogs covering SAP products, technology, and events. Get in the mix!
cancel
Showing results for 
Search instead for 
Did you mean: 
karthikarjun
Active Contributor
0 Kudos

Hi All,

In View Page 1 : Create one Button using below code

var butt = new sap.ui.commons.Button({

id : "id-butt",

text : "Submit",

press : oController.Submit

});

In Controller Page 1 :

Submit : function(){

//navigating between two views

var view1 = sap.ui.view({id:"idview12", viewName:"sapui4_firstprogram.Vs", type:sap.ui.core.mvc.ViewType.JS});//Initialize New View here
view1.placeAt("content");
var r = new sap.ui.getCore().byId("idview11");//By using this to call view 1
r.destroy();// Destroy the first View

}

Now First View will Destroy and you Can easy to navigate to Second View in a Single index Page...

Thanks,

Karthik A

3 Comments
Labels in this area