Date, day, month and year increment by clicking next & previous button in Appcelerator -


i need change date,day , month clicking next , previous button in appcelerator. if click on previous button date,day , month have decrement , if click on next button date,day , month have increment. appreciated. thank you

you use moment js library:

var moment = require("moment");  var = moment(); //today  now.add(1'days'); //tomorrow  now.subtract(1'days'); //yesterday 

to date formatted:

now.format('yyyy-mm-dd hh:mm:ss'); //will return string: 2016-05-25 11:01:32 

momentjs documentation:

http://momentjs.com/docs/


Comments

Popular posts from this blog

PySide and Qt Properties: Connecting signals from Python to QML -

c# - DevExpress.Wpf.Grid.InfiniteGridSizeException was unhandled -

scala - 'wrong top statement declaration' when using slick in IntelliJ -