You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flex.apache.org by "Mark Kessler (JIRA)" <ji...@apache.org> on 2015/01/30 17:25:36 UTC

[jira] [Commented] (FLEX-34731) Setting month to 1 in Date field ends up as 2

    [ https://issues.apache.org/jira/browse/FLEX-34731?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14298810#comment-14298810 ] 

Mark Kessler commented on FLEX-34731:
-------------------------------------

Could it be that the current day is the 30th and Feb only has 28 days, so it moves the month up by 1.  Try setting the day to something 28 or less first and then the month.  See if that corrects your issue.

> Setting month to 1 in Date field ends up as 2
> ---------------------------------------------
>
>                 Key: FLEX-34731
>                 URL: https://issues.apache.org/jira/browse/FLEX-34731
>             Project: Apache Flex
>          Issue Type: Bug
>    Affects Versions: Apache Flex 4.13.0
>            Reporter: Mike Robinson
>              Labels: easyfix
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> Cannot set the Date month value to February. 
> var date:Date = new Date();
> date.setMonth(1);  // month ends up as 2
> date.setMonth(0);  // correct
> date.setMonth(2); // correct



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)