Jul
04
2005
Getting datetime for first day of month
Posted by admin under
.NET

To get the first day in a month from a datetime value is of course very simple:
public static DateTime GetFirstInMonth(DateTime dt)
{
DateTime dtRet = new DateTime(dt.Year, dt.Month, 1, 0,0,0); return dtRet;
}