× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



awesome, thanks Carsten!

On Thu, Apr 11, 2013 at 9:23 AM, Flensburg, Carsten <Flensburg@xxxxxxxxxx>wrote:


Rick,

If you're looking for more information on the time zone topic, you can
find a lot of relevant links at the end of the following article on the
iProDeveloper site:
http://iprodeveloper.com/rpg-programming/apis-example-system-date-and-ti
me-apis-and-utilities

Some of the articles also include code examples of the date and time
APIs.

Cheers,
Carsten

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of rick baird
Sent: 11. april 2013 14:58
To: Midrange Systems Technical Discussion
Subject: Re: Converting local time to another time zone

Chuck and Carsten - PERFECT.

I tried to google it, but came up empty at first attempt.

Thanks to you both, and Scott too. That's exactly what I needed!

On Thu, Apr 11, 2013 at 4:37 AM, Flensburg, Carsten
<Flensburg@xxxxxxxxxx>wrote:

Hey Rick,

You can use the Retrieve Time Zone Description (QWCRTVTZ) API to
retrieve a list of all time zones on the system as well as the
associated time zone information:
http://pic.dhe.ibm.com/infocenter/iseries/v7r1m0/topic/apis/qwcrtvtz.h
tm

-Carsten

-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of rick baird
Sent: 10. april 2013 23:09
To: Midrange Systems Technical Discussion
Subject: Converting local time to another time zone

hey all,

I'm writing a service program where I will convert local time to
another time zone - or vise versa and return it. Basically, I need to
know what time it is somewhere else (a predefined remote location), or

what time it is locally based on a time in another time zone. Yes,
this will include areas that do not observe daylight savings time.

I will store the time zone for each individual remote location in a
file and retrieve the local time zone from system value QTIMZON. Once

I do that, I can do the time math, provided I know the UTC offset.

My questions are these:

Is there an api I can use (V5R4 and lower) to retrieve the list of
valid time zones listed in the WRKTIMZON?

Can I somehow retrieve the UTC offset for a particular time zone?
According to the help, this offset does not self adjust for daylight
savings time, so are the dates the time zone springs forward and back
stored somewhere? How does the operating system know how to spring
forward and back? Is that only stored for local time, or by time zone?

I'm hoping to not have to store the time zones, offsets and DST dates
myself if I can help it, but if that's the best way to go, then I need

to get started on that.

Thanks!

Rick
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing

list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at
http://archive.midrange.com/midrange-l.

This communication is intended only for use by the addressee.It may
contain confidential or privilegedinformation.
If you receive this communication unintentionally, please inform us
immediately and delete this e-mail and any attachments.
Warning: Although we have taken reasonable precautions to ensure no
viruses are present in this email, we cannot accept responsibility for

any loss or damage arising from the use of this email or attachments.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing

list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take
a moment to review the archives at
http://archive.midrange.com/midrange-l.


--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.

This communication is intended only for use by the addressee.It may
contain confidential or privilegedinformation.
If you receive this communication unintentionally, please inform us
immediately and delete this e-mail and any attachments.
Warning: Although we have taken reasonable precautions to ensure no
viruses are present in this email, we cannot accept
responsibility for any loss or damage arising from the use of this email
or attachments.
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.