Redigeeri

Jagamisviis:


DateTimeFormatInfo.GetDayName(DayOfWeek) Method

Definition

Returns the culture-specific full name of the specified day of the week based on the culture associated with the current DateTimeFormatInfo object.

public:
 System::String ^ GetDayName(DayOfWeek dayofweek);
public string GetDayName (DayOfWeek dayofweek);
member this.GetDayName : DayOfWeek -> string
Public Function GetDayName (dayofweek As DayOfWeek) As String

Parameters

dayofweek
DayOfWeek

A DayOfWeek value.

Returns

The culture-specific full name of the day of the week represented by dayofweek.

Exceptions

dayofweek is not a valid DayOfWeek value.

Remarks

For the default invariant DateTimeFormatInfo object, this method returns a string from the GregorianCalendar object.

dayofweek Return value
Sunday "Sunday"
Monday "Monday"
Tuesday "Tuesday"
Wednesday "Wednesday"
Thursday "Thursday"
Friday "Friday"
Saturday "Saturday"

Applies to

See also