title: WCF to Entity Framework converts my datetime into local time - how to stop?
body: <p>I've got a WCF service which receives records with datetime values, and saves them to an Azure SQL db, using Entity Framework 3.5, SP1. Running it locally, the records get saved to the database, all is well</p>
  
  <p>However, my IIS hosting is in a different timezone. When I upload the site to there and call the same service (with the exact same connection string, to the Azure SQL db), the records still get saved, but the time has moved back 5 hours.</p>
  
  <p>I've checked Fiddler, to watch the data going out, and it's in my local time. I've used the same service inside Azure hosting, and that saved fine too. I've got the same data going to another WCF service on the same host being saved with Linq2SQL, and that saves fine.</p>
  
  <p>The only difference then is Entity Framework - I'm guessing that my timezone information (GMT) is sent with the datetime, and so when the server in Eastern Seaboard time receives it, it converts it to the local time, 5 hours earlier. </p>
  
  <p>In a way, this is accurate, because at the moment (13:48), it is 5 hours earler - 08:48, but that's not what I want it to save to the database, I want it to save 13:48. Like I asked it to, so it makes sense when I query it</p>
  
  <p>This is probably really simple, and everyone else knows the answer, but I am a little puzzled. I'd really appreciate it if someone could point me in the right direction.</p>
  
  <p>many thanks</p>
  
  <p>Toby</p>