Page 1 of 2
Setting Datepicker value
Posted: Sat Jun 06, 2015 6:39 am
by Archana Bongale
I am trying to set Datepicker value from database. Database holds date value, which i read it in some "List" query, and using List's results I am trying to set the date picker value. I tried lots of options but I could not set properly date value.
I tried following link also and tried all of the options
https://getsatisfaction.com/apperyio/...
Setting Datepicker value
Posted: Sun Jun 07, 2015 3:46 pm
by Alena Prykhodko
Setting Datepicker value
Posted: Sun Jun 07, 2015 8:35 pm
by Archana Bongale
I tried the solution as per thread you recommended but it didn't work.
I added an "Alert" for newFormat", it did display right value but date picker component is not getting updated.
var newFormat = /(\d+.\d+.\d+)\s/gi.exec(value)[1];
return newFormat;
Setting Datepicker value
Posted: Mon Jun 08, 2015 9:45 am
by Serhii Kulibaba
Hello Archana,
Please check this JS code proccessor:
prevar date = new Date(value);
return ('0' + (date.getMonth() + 1)).slice(-2) + "/" + ('0' + date.getDate()).slice(-2) + "/" + date.getFullYear();/pre
Setting Datepicker value
Posted: Tue Jun 16, 2015 6:50 am
by Archana Bongale
I am still having issues
alert(value); == This gives proper date
var date = new Date(value);
alert(date); === This shows "invalid date"
alert(('0' + (date.getMonth() + 1)).slice(-2) + "/" + ('0' + date.getDate()).slice(-2) + "/" + date.getFullYear()); === This shows "Nan/Nan/Nan"
Setting Datepicker value
Posted: Tue Jun 16, 2015 5:47 pm
by Serhii Kulibaba
This gives proper date
Please write here, what do you see
Setting Datepicker value
Posted: Wed Jun 17, 2015 6:53 am
by Archana Bongale
Setting Datepicker value
Posted: Thu Jun 18, 2015 7:57 pm
by Serhii Kulibaba
It works fine for us. Please provide us with a public app link (http://devcenter.appery.io/documentat...) and steps to reproduce.
Setting Datepicker value
Posted: Thu Jun 18, 2015 9:04 pm
by Archana Bongale
Is there a way I can share the app with you and not make it public?
Setting Datepicker value
Posted: Thu Jun 18, 2015 9:07 pm
by Evgene Karachevtsev
Hello Archana ,
Yes, you can, please just tell us its name:
https://devcenter.appery.io/documenta...