Use four digit to construct the year field : Date : Development Flash / Flex / ActionScript examples


Flash / Flex / ActionScript examples » Development » Date »

 

Use four digit to construct the year field


 

package{
  import flash.display.Sprite;
  
  public class Main extends Sprite{
    public function Main(){
        var dWhen:Date = new Date(1978913);
        trace(dWhen.getFullYear());  // Displays: 1978
        
        var dThen:Date = new Date(177964);
        trace(dThen.getFullYear());  // Displays: 1779
        

    }
  }
}

        



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


Flash / Flex / ActionScript examples

 Navioo Development
» Date