Using datetimekind. Is there supposed to be a conversion?

  • Thread starter Thread starter Claire
  • Start date Start date
C

Claire

public DateTime d2 = new DateTime(2000, 1, 1, 15, 0, 0, DateTimeKind.Utc);
MessageBox.Show(d2.ToLocalTime().ToString());

The messagebox shows "01/01/2000 15:00:00" where I expected 14:00 (I'm GMT +
1, VS 2005)
Am I getting the correct result?
Im not sure what I can expect from using DateTimeKind.Utc but help suggests
that the ToLocalTime() function would return a conversion.

thanks :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top