Yeah, you can do subtraction.  Like, here's what I got this morning after
coffee:

// local time minus UTC
var d:Date = new Date();
var hours:Number = d.getHours();
var utc:Number = d.getUTCHours();
var offset:Number = hours - utc;
trace(offset); // prints -5

Looks right since you got -5, right (I'm on east coast)?

As far as timezone offset, not sure... maybe I just don't know what to look
for the in the API?  I can't use AS3, have to use AS2/AS1 (since this is for
a phone):

http://livedocs.adobe.com/flash/8/main/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Parts&file=00002128.html#wp206454



On 2/24/07, Philipp Kewisch <[EMAIL PROTECTED]> wrote:
>
>
> The offset is your timezone offset in hours. Depending on which side
> you are on, your offset is either -5 hours or +19 hours. (i.e -05:00)
>
> You probably need more than just the hours. Does flash not have a way
> to subtract two dates or give you your timezone offset?
>
> Philipp
>
>
>
> On Feb 24, 5:39 am, "Jesse Warden" <[EMAIL PROTECTED]> wrote:
> > Ok, Jayred helped me understand the time offset is needed if you are not
> on
> > GMT time (2nd reply of his):
> >
> > http://groups.google.com/group/google-calendar-help-dataapi/browse_th...
> >
> > And then I read this (4.2 Local Offsets section):
> >
> > http://www.ietf.org/rfc/rfc3339.txt
> >
> > So, they said I could basically subtract my local timezone from UTC to
> get
> > the offset (I think).  So, booted up Flash, and did this:
> >
> > // currently 11:34pm when code was run
> > var d:Date = new Date();
> > trace(d.getHours());      // prints out 23
> > trace(d.getUTCHours());   // prints out 4
> >
> > Rad.  So, my time offset would be:
> >
> > -04:00
> >
> > Correct?
> >
> > Meaning, the date string I'd send would sort of look like:
> >
> > http://www.google.com/calendar/feeds/[removed some id
> >
> thinghere]%40group.calendar.google.com/private/full?start-min=2007-02-18T00:00:00-04:00&start-max=2007-02-18T23:59:59-04:00
> >
> > ???
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Calendar Data API" group.
To post to this group, send email to 
[email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/google-calendar-help-dataapi?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to