FormatDate DateTime(?)

.FormatDate()

Formats a date as a long string in the form "d MMM yyyy" ie: 1 Oct 2010.

Method

public static string FormatDate(this DateTime dt)
public static string FormatDate(this DateTime? dt)
DateTime(?) dt

DateTime or DateTime? value to convert into the string format "d MMM yyyy".

Example

C#
string today = DateTime.Today.FormatDate();