TimeZoneInfo.StandardName 속성

정의

해당 표준 시간대의 표준 시간을 나타내는 표시 이름을 가져옵니다.

public:
 property System::String ^ StandardName { System::String ^ get(); };
public string StandardName { get; }
member this.StandardName : string
Public ReadOnly Property StandardName As String

속성 값

String

표준 시간대 표준 시간의 표시 이름입니다.

예제

다음 예제에서는 표준 시간대의 표준 시간 이름 또는 일광 절약 시간 이름을 표시할지 여부를 결정 하는 메서드를 사용 하 여 IsDaylightSavingTime(DateTime) 명명 DisplayDateWithTimeZoneName 된 메서드를 정의 합니다.

private void DisplayDateWithTimeZoneName(DateTime date1, TimeZoneInfo timeZone)
{
   Console.WriteLine("The time is {0:t} on {0:d} {1}", 
                     date1, 
                     timeZone.IsDaylightSavingTime(date1) ?
                         timeZone.DaylightName : timeZone.StandardName);   
}
// The example displays output similar to the following:
//    The time is 1:00 AM on 4/2/2006 Pacific Standard Time
let displayDateWithTimeZoneName (date1: DateTime) (timeZone: TimeZoneInfo) =
    printfn $"The time is {date1:t} on {date1:d} {if timeZone.IsDaylightSavingTime date1 then timeZone.DaylightName else timeZone.StandardName}" 
// The example displays output similar to the following:
//    The time is 1:00 AM on 4/2/2006 Pacific Standard Time
Private Sub DisplayDateWithTimeZoneName(date1 As Date, timeZone As TimeZoneInfo)
   Console.WriteLine("The time is {0:t} on {0:d} {1}", _
                     date1, _
                     IIf(timeZone.IsDaylightSavingTime(date1), _
                         timezone.DaylightName, timezone.StandardName))   
End Sub
' The example displays output similar to the following:
'    The time is 1:00 AM on 4/2/2006 Pacific Standard Time

설명

표시 이름은 Windows 운영 체제에 설치된 문화권에 따라 지역화됩니다.

속성은 StandardName 클래스의 StandardName 속성과 TimeZone 동일합니다.

운영 체제 언어가 영어인 경우 속성 값은 일반적으로 속성 값 StandardName Id 과 동일하지만 항상 같지는 않습니다.

적용 대상