Hell there, i have a button creating a new view everytime i click on it. If i close my app, i open again the app, the views i created disapeared (so normal !!! ). How i can save in memory these new views?
var scrollable = Ti.UI.createScrollView({ height: 400, top: 10, width: Ti.UI.FILL, layout: 'vertical' }); var createCategory = Ti.UI.createButton({ title:L('newCat'), top: 10 height: 40 width: 100 color: "#fff", backgroundColor:'#3d93eb', borderRadius: 4, textAlign: 'center', font:{fontSize: 31} }); win.add(scrollable); win.add(createCategory); createCategory.addEventListener('click',function(){ var newCategory = Ti.UI.createView({ width: 200, height: 80, top: 5, backgroundColor:'#f4f4f4', textAlign:'center', color: '#323131' }); scrollable.add(newCategory); });