Hello, I can“t get the navbar to appear, i've searched for examples in the kitchen sink and in the Appcelerator API, here is the example code in the API,and i doesn't work either:
var win = Titanium.UI.createWindow(); var win1 = Titanium.UI.createWindow({ backgroundColor:"red", title:"Red Window" }); var nav = Titanium.UI.iPhone.createNavigationGroup({ window: win1 }); win.add(nav); win.open(); var win2 = Titanium.UI.createWindow({ backgroundColor:"blue", title:"Blue Window" }); nav.open(win2,{animated:true});
Does any one know what is happening?
1 Answer
Accepted Answer
i don't believe you need to, or can put a navGroup in a window.
try this
var win = Titanium.UI.createWindow(); var win1 = Titanium.UI.createWindow({ backgroundColor:"red", title:"Red Window" }); var nav = Titanium.UI.iPhone.createNavigationGroup({ window: win1 }); win.add(nav); var win2 = Titanium.UI.createWindow({ backgroundColor:"blue", title:"Blue Window" }); win.open(); var btn = Ti.UI.createButton({ title:'next' }); btn.addEventListener('click', function(e) { nav.open(win2) }); win1.setRightNavButton(btn);See more detailed posting here
Your Answer
Think you can help? Login to answer this question!