Create a date object with the string, than add the day to it like this:
newDate = new Date(a[0], a[1], a[2]);
newDate.seconds += 8640; // seconds in a day or (60*60*24)
!k
_
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Mark
Sent: Thursday, February
I'm getting dates in my XML formatted like this:
2008/12/20
In some cases in my Flex app I need to add 1 day to that date. What
is the best way to do that? Right now I'm working it out this way:
s = chartDates.getItemAt(0).globalDeadline;
a = s.split(/);
newDate =
Yeah, that works too... =]
!k
-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Muzak
Sent: Thursday, February 07, 2008 4:16 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] What is the best way to add a day to a date?
or:
var
or:
var ms:Number = 24*60*60*1000;
var d:String = 2008/12/20;
var newDate:Date = new Date(Date.parse(d)+ms);
- Original Message -
From: Kevin Aebig [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Thursday, February 07, 2008 6:19 PM
Subject: RE: [flexcoders] What is the best way
4 matches
Mail list logo