I just want to add 1 day to a DateTime
. So I wrote:
DateTime date = new DateTime(2010, 4, 29, 10, 25, 00);
TimeSpan t = new TimeSpan(1, 0, 0, 0);
date.Add(t);
Console.WriteLine("A day after the day: " + date.ToString());
I thought the result would be: 2010 04 30- 10:25:00
but I'm still getting the initial date.
What's wrong?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…