How we can find the last date of any given month and year
how we can find the last date of any given month and year means if given month 3 or macrh and given year 2015 then how we can find the last date of that month
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.


Michal HabalcikRank #902 · 2.3K reputationPosted Jan 14, 2015, 1:07 AM EST
var date = new DateTime(2015, 3, 1).AddMonths(1).AddDays(-1);
the first DateTime parameter is the year, the second is month.
Riddhi ValechaRank #794 · 2.9K reputationPosted Jan 14, 2015, 1:08 AM EST