LocalTimeZone

LocalTimeZone[]
gives the current time zone for the current geo location.

LocalTimeZone[loc]
gives the current time zone for the geo location specified by loc.

LocalTimeZone[loc,date]
gives the time zone for the geo location loc on the specified date.

LocalTimeZone[loc,date,"prop"]
gives the specified property of the time zone.

DetailsDetails

  • LocalTimeZone[] is equivalent to $TimeZone.
  • The geo location loc can be specified by a GeoPosition object or by giving an appropriate Entity object.
  • LocalTimeZone by default returns a number giving the offset from GMT in hours.
  • Possible properties include:
  • "NumericOffset"offset in hours as a number
    "Offset"offset as a Quantity object

ExamplesExamplesopen allclose all

Basic Examples  (3)Basic Examples  (3)

Get the current local numeric time zone offset:

In[1]:=
Click for copyable input
Out[1]=

Get the local time zone for London on different dates:

In[1]:=
Click for copyable input
Out[1]=

Get the current time zone offset for Oslo as a Quantity:

In[1]:=
Click for copyable input
Out[1]=
Introduced in 2014
(10.0)