All C# extension methods for type datetime
- 
        DateRangeA simple date range 
- 
        IsWeekendLets you easily figure out ifdateTime holds a date value that is a weekend. 
- 
        IntersectsReturns true if two date ranges intersect. 
- 
        AgeGet the actual age of a person 
- 
        IsBetweenChecks if the date is between the two provided dates 
- 
        DateTimeFormatThis is extension method for format the data time into the string with pattern specific and current culture. For more information please read at my blog http://weblogs.asp.net/thangchung/archive/2010/11/01/datetime-formating-extension-method.aspx 
- 
        AddWorkdaysA modification to the AddDay function that adds an integer number of weekdays to a date, starting the count at the first weekday after the current day. This is a typical method for calculating B2B service delivery and billing due dates. 
- 
        GetLastDayOfMonthGets the last date of the month of the DateTime. 
- 
        ToUnixTimestampConverts a System.DateTime object to Unix timestamp. 
- 
        DateDiffDateDiff in SQL style. The following DateParts are implemented: - "year" (abbr. "yy", "yyyy") - "quarter" (abbr. "qq", "q") - "month" (abbr. "mm", "m") - "day" (abbr. "dd", "d") - "week" (abbr. "wk", "ww") - "hour" (abbr. "hh") - "minute" (abbr. "mi", "n") - "second" (abbr. "ss", "s") - "millisecond" (abbr. "ms") 
- 
        ToDateTimeGets a nullable DateTime object from a string input. Good for grabbing datetimes from user inputs, like textboxes and querystrings. 
- 
        IsInRangeDetermines if a date is within a given date range 
- 
        IsLeapYearReturns whether or not a DateTime is during a leap year. 
- 
        ToFriendlyDateStringThe idea behind the ToFriendlyDateString() method is representing dates in a user friendly way. For example, when displaying a news article on a webpage, you might want articles that were published one day ago to have their publish dates represented as "yesterday at 12:30 PM". Or if the article was publish today, show the date as "Today, 3:33 PM". 
- 
        ToShamsiDateConvert DateTime to ShamsiDateString 
- 
        EndOfTheMonthReturns datetime corresponding to last day of the month 
- 
        ToStringreturns a formatted string on a nullable date 
- 
        ElapsedGet the elapsed time since the input DateTime 
- 
        NextSundayGet's the date of the upcoming Sunday. 
- 
        EndOfTheDayReturns datetime corresponding to day end 
- 
        AddTimeAdds time to existing DateTime 
- 
        ToRFC822DateStringConverts a regular DateTime to a RFC822 date string used for RSS feeds 
- 
        ThisWeekMondayReturns a DateTime representing the Monday of the current week. Depends on System.Globalization 
- 
        TimeElapsedInspiration for this extension method was another DateTime extension that determines difference in current time and a DateTime object. That one returned a string and it is more useful for my applications to have a TimeSpan reference instead. That is what I did with this extension method. 
- 
        AddWorkDaysThis extension add "working day" to a date, where working day means from Monday to Friday. 
- 
        IsLeapDayChecks if the current day is a leap day 
- 
        RemoveTicksLegible way to remove ticks from a datetime. Use instead Add negative days 
- 
        NullDateToStringPrints out a nullable datetime's value (if its not null) in the string format specified as a parameter. A final parameter is specified for what to print if the nullable datetime was, in fact, null. 
- 
        BeginningOfTheMonthReturns datetime corresponding to first day of the month 
- 
        ElapsedSecondsGest the elapsed seconds since the input DateTime 
- 
        ThisWeekFridayReturns a DateTime representing the Friday of the current week. Depends on System.Globalization. 
- 
        ToOracleSqlDateConverts a Timestamp to a String which can be used in a Oracle SQL Query 
- 
        BeginningOfTheDayReturns datetime corresponding to day beginning 
- 
        LengthOfTimereturn the length of time between the start and current date 
- 
        IsLastDayOfTheMonthReturns whether the given date is the last day of the month. 
- 
        DateTimeFloor;DateTimeCeilingFloor, Ceiling, Midpoint and Rounding calculations for various time intervals. 
- 
        GetDateReturn the current date and time 
- 
        NextDayOfWeekWill return the next occurring day of week 
- 
        GetMonthDiffCompute dateTime difference 
- 
        DateTime Use in Library SystemManagementthis extension method is Used in Library System Management for return Recive book Date if you use this method this add to Date.Now 14 Days with change the Year and Month Day 
- 
        GetTotalMonthDiffCompute dateTime difference precisely 
- 
        GetSaturdayThis code will provide the Sunday DateTime from the week of DateTime object the extension method is called from. 
- 
        GetSundayThis code will provide the Sunday DateTime from the week of DateTime object the extension method is called from. 
- 
        NextAnniversaryCalculates the next anniversary of an event after the initial date on the Gregorian calendar. Use the original event date or the event month/event day as a parameters. The optional parameter, preserveMonth will determine how to handle an event date of 2/29. Set to true will use February 28 for a standard year anniversary and set to false will use March 1 for a standard year anniversary. 
- 
        CurrentDateTimeInAmsterdamGet the current date time in Amsterdam 
- 
        NextGet next day of the week 
- 
        CompareWithoutMinutesCompares two datettime objects ignoring minutes and seconds 
- 
        FirstDayOfMonthReturn the first day of the mounth for a given date 
- 
        DateTimeCheckValvethis ExtensionMethod check if startdate is null reutrn the min value of datetime and if the end date is null return the max value