Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2008

[Date Index] [Thread Index] [Author Index]

Search the Archive

Bug in DateString with TimeZone?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg93440] Bug in DateString with TimeZone?
  • From: Nacho <ncc1701zzz at gmail.com>
  • Date: Sat, 8 Nov 2008 03:59:02 -0500 (EST)

Hello all.

I'm trying to get the time in format HHMM in Timezone GMT and I'm
having problems, TimeZone works weird.

I don't know if it is a bug. My Timezone is GMT+1, and I get:

In[25]:= DateString[{"Hour", "", "Minute"}]
Out[25]= "2122"  (It's OK)

In[26]:= DateString[TimeZone -> 0]
Out[26]= "Fri 7 Nov 2008 20:22:17" (It's OK)

In[27]:= DateString[{"Hour", "", "Minute"}, TimeZone -> 0]
Out[27]= "2222" (Wrong! this is GMT+2)

I solved my problem using:

In[28]:= DateString[AbsoluteTime[TimeZone -> 0], {"Hour", "",
"Minute"}]
Out[28]= "2022"

but I think there is a problem with TimeZone...

Any hint?

Thanks.


  • Prev by Date: Re: $Aborted
  • Next by Date: Command line options
  • Previous by thread: Re: Trig Substitution
  • Next by thread: Re: Bug in DateString with TimeZone?