UTC2Local ( UTC ; Timezone ; Decimals )
Convert a UTC-milliseconds time into a local time corrected for DST.
Average rating: 5.0 (1 vote) Log in to vote
Menno van Beek - Show more from this author
Van Beek Zakelijke Software
Function definition: (Copy & paste into FileMaker's Edit Custom Function window)
Convert a UTC-milliseconds time (or number) into a local time corrected for DST. If your area or the particular area you calculate the timestamp for does not use DST, it's easy to change the formula a bit by adding an extra parameter.
for example: UTC2Local ( UTC ; Timezone ; Decimals ; use_dst ) and change the part "dst = If ( utc ≥ dst0 and utc < dst1 ; 3600 )" into "dst = Case ( not ( use_dst ) ; 0 ; utc ≥ dst0 and utc < dst1 ; 3600 )" and enter 1 if you do want to correct for DST
Menno van Beek, Van Beek Zakelijke Software
Sep 1, 2018
|EDITED the formula: Corrected a little issue in the DST correction. The previous version would calculate an incorrect result when the last day of the given month is on a Sunday. The first occurrence would have been on March 24 2019|
Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.