Odd, I've always had to adjust for the timezone, and I've always  
built on XP or OSX.  I just assumed that was the way it was supposed  
to be.


On Oct 30, 2007, at 11:29 AM, Scott Melby wrote:

> My application uses many dates.  Dates are always passed between the
> back end web service and the front end flex app as timestamps,
> milliseconds since epoch.  Yesterday I switched to a dev. box that is
> running VISTA... now all of the dates in my application are off by the
> timezoneOffset.  I can correct them easily enough as follows:
>
>          var millis:Number = d.time;
>          var offsetMillis = d.timezoneOffset * 60 * 1000;
>          d.time = millis + offsetMillis;
>
> But, I am not sure that this is the right thing to do.  I went back  
> and
> checked my XP machine setup and verified that it was using the correct
> timezone, and it was.  So... why would this behave differently?  The
> behavior seems to be dictated by the OS that the .swf file was  
> built on
> (or the flex sdk compiler that was used) and not by the OS that the
> flash player is running on.  I verified this by accessing a site  
> running
> a .swf that I built on XP from both systems... that one handled  
> dates as
> I expected (no manual TZ adjustment needed).  Then I accessed a site
> running a .swf that I built on my vista box from an XP client and an
> vista client.  Both exhibited the need for a time zone correction.
>
> Can anybody tell me what is expected here?  Should I adjust for  
> timezone
> as above every place in my code where I create dates?  Any help is
> appreciated.
>
> Scott
>
>
>
> --
> Flexcoders Mailing List
> FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives: http://www.mail-archive.com/flexcoders% 
> 40yahoogroups.com
> Yahoo! Groups Links
>
>
>

Reply via email to