Good morning AskPerf! Anshuman here with a quick post on timestamp differences in Windows Explorer when accessing FTP sites.
Scenario
On Windows 7(SP1), Windows 8, and Windows 8.1, you access a folder using ftp by opening an explorer window and typing in the FQDN FTP URL in the address bar. In the FTP folder view, if you access the properties of a file, you may notice that the Modified time in the properties of the file may not match the Date modified time stamp displayed in the detailed view in explorer. See screenshot below:
This behavior can be observed if the local time set on the machine from where you access the FTP folder in explorer view is set to a Time Zone other that the UTC time. In this case you will see that the Timestamp of the item, when its property is accessed is displayed as UTC, while the timestamp that we see under the Date modified column for the same file is shown as per the Time Zone that’s set on the machine.
Please note that both the timestamps are correct. The difference is due to the Time Zone bias added or subtracted from the UTC time.
Additional Resources
- Daylight Saving Time Help and Support Center
- How Outlook handles time zones for meeting requests
- How time zone normalization works in Outlook 2010 and Outlook 2013
-Anshuman Ghosh
So is any way to avoid this behavior except using UTC time?
Here is my take on the problem: I want to have the capability of displaying THE TIME THAT I AM EDITING A FILE, in the proper Time Zone, either MST or DST, and also THE LAST TIME I EDITED THE FILE, ALSO in either MST or DST. So my current Time Zone and the File’s Time Zone don’t have to be the same. As a matter of fact, my PC and the File can reside anywhere on earth SEPARATELY. But the Time Zones should display correctly. In actual practice, the File almost always resides on my PC, but I am persnickety and want this logic to work with as little exception code as possible. …So, I did some InterWebb snooping and found a set of algorithms that will return the ranges of DST and MST, month and day, between the years 1900 and 2099. You provide the year (I also provided a Boolean that tells if it West of UTC (-), or at or East of UTC (0,+)), and it will return start and end of DST, month/day. You compare your program’s request date/time, and the File’s “WRITE” Date/Time, and label them appropriately for display. See the following link for the algorithms : http://www.delphiforfun.org/Programs/Math_Topics/DSTCalc.htm