Can both methods deliver different results under certain circumstances? Same question for negative values...
Asked
Active
Viewed 313 times
1
-
1You might find this helpful: http://stackoverflow.com/questions/4793788/datetime-adddays-vs-calendar-adddays – DKnight Feb 22 '11 at 13:58
2 Answers
2
They always do the same thing. AddMonth and AddYears will vary but a week is always 7 days

Robert Levy
- 28,747
- 6
- 62
- 94
2
Straight from Reflector:
public DateTime AddDays(double value)
{
return this.Add(value, 86400000);
}
public virtual DateTime AddWeeks(DateTime time, int weeks)
{
return this.AddDays(time, weeks * 7);
}
Note, however, that AddWeeks is defined as virtual
.

Please treat your mods well.
- 4,321
- 1
- 25
- 35