CSharp examples for System:DateTime Month
Gets the begin of month.
using System.Text; using System.Linq; using System.Collections.Generic; using System;/*www .j a v a 2 s . c o m*/ public class Main{ #region M?todos /// <summary> /// Gets the begin of month. /// </summary> /// <returns>The begin of month.</returns> /// <param name="value">The DateTime it self.</param> public static DateTime GetBeginOfMonth(this DateTime value) { return new DateTime(value.Year, value.Month, 1, 0, 0, 0, 0); } }