time constant

  • Thread starter Thread starter GS
  • Start date Start date
G

GS

I understand and can use time literals like
#2:30:00 PM
but what If I want to specify time zone -7?
 
GS,

Your datetime is forever accoording your timezone as given in your system
settings.

You can use however by instance UTC to tell that to the datetime structure.

There is by the way in my opinion no TimeZone 7. Maybe are you using that
speaking localy. Globaly are codes used with 3 characters.

Beside inside the English speaking culture for times and even for that
inside the USA culture it is in my opinion not wise to use those litterals,
they are completely build around those cultures which is about 10% (and for
datetime even less) of the world cultures. Using the New DateTime statement
with ISO gives you a more general used method.

Just my thought,

Cor
 
you are definitely right about UTC. In this particular application, the
users are limited to a locality and the users may travel but the actual time
to compare is like 2:30 MST or 4:30 EST. due to business practise. I don't
have preference one way or another although I am not conversant with UTC
conversion nor the classes.

Ultimately, literals will not be embedded in the application but will be in
application or user setting depending on applicability. I am a bit
concerned though there are a lot people not familiar with UTC but they
understand MST, EST ...etc. In other word the user interface will probably
have to deal with non UTC time.
 
Back
Top