2

I have a winforms client application which is written in c# 4.0 that sends a simple datatable (in a dataset) to the server , which is written in vb.net 4.0. The datatable is sent through a web service. both client and server are on the same computer. This has been working fine for many years.

Now I get a strange behaviour with a datatable generated from a csv file.

Here it how it looks on the client side: enter image description here

and here is the server side: enter image description here

for some reason, the first row time has shifted from 2:55 AM to 03:55 in the server. This results in a duplicate key. what's up with that?

one of the strangest bugs I've ancountered. would appreciate any help with this one - thanks.

omer schleifer
  • 3,897
  • 5
  • 31
  • 42
  • I would assume somewhere along the way you are adding 1 to it. – NoviceDeveloper May 07 '13 at 12:16
  • 1
    You would assume wrong. please give me some credit. – omer schleifer May 07 '13 at 12:19
  • This really looks like a difference in time zone or even possibly locale. See the difference in not only the time but the date format as well e.g. 29/03 vs 03/29 – mikey May 07 '13 at 12:21
  • 1
    Are you running the 2 programs as different users? Are these forms applications or ASP.NET applications? Some things to check out here http://stackoverflow.com/questions/2288383/where-is-the-system-locale-culture-set-for-net – mikey May 07 '13 at 12:24
  • @mikey ,thanks you are right of course. the server is under IIS user and the client is under another user. on march 29 dylight saving time ended in my country. Thanks a lot :) – omer schleifer May 07 '13 at 12:45
  • Glad to know it was solved. Could one of you please add it as an answer and then the appropriate party can mark this as answered, so that people like me looking for people to help don't think it's still unanswered :D – Adrian May 08 '13 at 22:52

1 Answers1

0

As suggested by @mikey, the problem was that client used a local user account whereas the server used the IIS acount.

One of those acounts was set to use daylightsaving time, the other was not. In my country, daylight saving time ended on march 29, so this resulted in a conflict between server time and client time, even though both were on the same computer.

Mikey , thanks again :)

omer schleifer
  • 3,897
  • 5
  • 31
  • 42