I get this kind of data from XML document :
2012-08-29T18:18:00+02:00
and I’d like to convert it with the DateTime object. So I can manage it as I want, getting only day and/or month.
But if I do it :
DateTime.Parse("2012-08-29T18:18:00+02:00").Date
I get somethings like \/Date(1346191200000)\/ :O
Where am I wrong? I think I need to specify the type of date when I parse it?
After the suggestions, I tried with this data :
string dataStr = "2012-11-15T13:50:58+01:00";
DateTime data = DateTime.Parse(dataStr).Date;
Response.Write(data.Hour + "<br />");
but the output is 0, so the time is missing. Why?
According to your latest update: