Problem is, the govt keeps changing the rules. I have one installation where this is so critical, the admin has to put in the two dates every year. I haven't had to touch that in 20 years. Sweet.
Dennis McGrath Software Developer QMI Security Solutions 1661 Glenlake Ave Itasca IL 60143 630-980-8461 [email protected] -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Nielsen, Midge D CTR USAF ACC 388 RANS/JT3 Sent: Monday, November 28, 2011 9:21 AM To: RBASE-L Mailing List Subject: [RBASE-L] - RE: Determining Whether it is Daylight Saving Time or Not I built this for determining if the flight date of a mission was during daylight savings time or not. You could change the variable vfldate to today's date. -- This module determines if date is subject to Daylight Savings Time, For Zulu calculations LABEL dst SET VAR vmonth INT, viday INT, viyr INT, vdy1 INT, vdy2 INT, vdst INT SET VAR vfirst DATE SET VAR vmonth = (IMON(.vfldate)) IF vmonth < 3 OR vmonth > 11 THEN SET VAR vdst = 0 ELSE SET VAR vdst = 1 ENDIF SET VAR viday = (IDAY(.vfldate)) -- Calculate DayLight Savings In March IF vmonth = 3 THEN IF viday < 8 THEN SET VAR vdst = 0 ELSE IF viday > 14 THEN SET VAR vdst = 1 ELSE SET VAR viyr = (IYR(.vfldate)) SET VAR vfirst = (RDATE(3,14,.viyr)) SET VAR vdy1 = (IDWK(.vfirst)) SET VAR vdy2 = (IDWK(.vfldate)) IF vdy2 = 7 THEN SET VAR vdst = 1 ELSE IF vdy2 = vdy1 THEN SET VAR vdst = 1 ELSE IF vdy1 = 7 THEN SET VAR vdst = 0 ELSE IF vdy1 < vdy2 THEN SET VAR vdst = 0 ELSE SET VAR vdst = 1 ENDIF ENDIF ENDIF ENDIF ENDIF ENDIF ENDIF -- Calculate DayLight Savings For November IF vmonth = 11 AND viday > 7 THEN SET VAR vdst = 0 ENDIF IF vmonth = 11 AND viday <= 7 THEN SET VAR viyr = (IYR(.vfldate)) SET VAR vfirst = (RDATE(11,1,.viyr)) SET VAR vdy1 = (IDWK(.vfirst)) SET VAR vdy2 = (IDWK(.vfldate)) IF vdy2 = 7 THEN SET VAR vdst = 0 ELSE IF vdy2 = vdy1 THEN IF vdy1 < 7 THEN SET VAR vdst = 1 ELSE SET VAR vdst = 0 ENDIF ELSE IF vdy2 < vdy1 THEN SET VAR vdst = 0 ELSE SET VAR vdst = 1 ENDIF ENDIF ENDIF ENDIF -- CLEAR VAR vimon, viday, viyr, vfirst, vdy1, vdy2 RETURN Midge Nielsen JT3/UTTR Programmer (801) 777-9653 -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Fitts, David A. Sent: Wednesday, November 23, 2011 12:01 PM To: RBASE-L Mailing List Subject: [RBASE-L] - RE: Determining Whether it is Daylight Saving Time or Not Here is a link to a federal government web site that offers a small 32 bit executable to help you get the info you want at any given time. How to get it into Rbase is more than I can help with so good luck. http://www.nist.gov/pml/div688/grp40/its.cfm David Fitts State of Maine Risk Management Division 287-3352 1-800-525-1252 ________________________________ From: [email protected] [mailto:[email protected]] On Behalf Of Paul Buckley Sent: Tuesday, November 22, 2011 10:39 AM To: RBASE-L Mailing List Subject: [RBASE-L] - Determining Whether it is Daylight Saving Time or Not Is there a way to determine if it is daylight saving time or standard time? I have a need to not only record date & time but also this information. Thanks in advance, Paul Buckley

