fredag den 4. september 2009

Datetime in Rails and C#

I am developing a desktop application in C#, that accesses a rails webservice, backed by mysql. One of my tables has a datetime column, and I had some trouble posting to that table. It turns out, that the DateTime.ToString method of C# accepts several different format strings , but none of them match the datetime format of my webservice, so I had to massage it a bit - the massage being dependent on the format string.

A small error, but it took a while to find the source, so just posting this in case others have the same problem.