Dot Net Dunk

Wandering in the land of .NET
posts - 42, comments - 22, trackbacks - 187

My Links

News

Archives

Post Categories

Blog Roll

DateTime.Now and BizTalk

My colleague The Arch Hacker (dude, lame online name ;-), reports a supposed problem with DateTime.Now behaviour under BizTalk in that it seems to ignore daylight saving time here in the UK.

A little bit of lateral thinking and I've suggested that what it's probably doing is returning a timezone-free time. This is because BizTalk is running under a service account that does not have a user profile, hence there is no timezone information available to .NET. It is probably just using the BIOS time and treating it as universal time. In the UK, this just happens to be 1hr different to GMT, which makes it look as if it's the daylight savings time that's broken. That's just a red herring - it's actually just applying no timezone information at all.

I've not tested out this theory, but hopefully The Arch Hacker will do. .NET DateTime has a lot of hidden subtleties (mainly because it does not hold timezone information) and I strongly recommend every .NET programmer reads this MSDN article.

Print | posted on Monday, October 04, 2004 1:44 PM | Filed Under [ BizTalk Server C#/.NET Development ]

Feedback

Gravatar

# re: DateTime.Now and BizTalk

hehe - lame online name eh? The moniker was duly given to me by a BizTalk guy from Microsoft UK, so it sort of stuck ;-)
10/4/2004 1:49 PM | TAH

Post Comment

Title  
Name  
Email
Url
Comment   
Please add 4 and 7 and type the answer here:

Powered by: