CultureAndRegionInfoBuilder.Unregister(String) 메서드
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
사용자 지정 문화권을 로컬 컴퓨터에서 삭제합니다.
public:
static void Unregister(System::String ^ cultureName);
public static void Unregister (string cultureName);
static member Unregister : string -> unit
Public Shared Sub Unregister (cultureName As String)
매개 변수
- cultureName
- String
삭제할 사용자 지정 문화권의 이름입니다.
예외
cultureName
이 종속 문화권의 부모 문화권이거나 콘솔 대체(fallback) 사용자 인터페이스 문화권인 경우
사용자에게 관리 권한이 없는 경우
cultureName
이 찾을 수 없는 문화권을 지정할 경우
예제
다음 예제는 Unregister 메서드.
// This example demonstrates the System.Globalization.Culture-
// AndRegionInfoBuilder Unregister method.
// Compile this example with a reference to sysglobl.dll.
/*
Notes:
This example deletes the custom culture x-en-US-sample.nlp
file, but not the %winnt%\Globalization directory that contains the file.
*/
using System;
using System.Globalization;
class Sample
{
public static void Main()
{
try
{
Console.Clear();
Console.WriteLine("Unregister the \"x-en-US-sample\" " +
"custom culture if it already exists...");
CultureAndRegionInfoBuilder.Unregister("x-en-US-sample");
Console.WriteLine("The custom culture was unregistered successfully.");
}
catch (Exception e)
{
Console.WriteLine("Error while unregistering...");
Console.WriteLine(e);
}
}
}
/*
This code example produces the following results:
Unregister the "x-en-US-sample" custom culture if it already exists...
The custom culture was unregistered successfully.
*/
' This example demonstrates the System.Globalization.Culture-
' AndRegionInfoBuilder Unregister method.
' Compile this example with a reference to sysglobl.dll.
'
' Notes:
' This example deletes the custom culture x-en-US-sample.nlp
' file, but not the %winnt%\Globalization directory that contains the file.
'
Imports System.Globalization
Class Sample
Public Shared Sub Main()
Try
Console.Clear()
Console.WriteLine("Unregister the ""x-en-US-sample"" " & _
"custom culture if it already exists...")
CultureAndRegionInfoBuilder.Unregister("x-en-US-sample")
Console.WriteLine("The custom culture was unregistered successfully.")
Catch e As Exception
Console.WriteLine("Error while unregistering...")
Console.WriteLine(e)
End Try
End Sub
End Class
'
'This code example produces the following results:
'
'Unregister the "x-en-US-sample" custom culture if it already exists...
'The custom culture was unregistered successfully.
'
설명
합니다 Unregister 메서드는 역순으로는 Register 메서드. 메서드는 Register 사용자 지정 문화권을 로컬 컴퓨터의 Windows API GetWindowsDirectory 함수에서 반환된 디렉터리의 전역화 하위 디렉터리에 파일로 저장합니다. Unregister 메서드 컴퓨터에서 사용자 지정 문화권 지속형된 파일을 삭제 합니다. 이 파일은 삭제 후 컴퓨터 메모리에 사용자 지정 문화권의 기존 인스턴스가 계속 정상적으로 작동 하지만 사용자 지정 문화권의 새 인스턴스를 만들 수 없습니다.
적용 대상
추가 정보
GitHub에서 Microsoft와 공동 작업
이 콘텐츠의 원본은 GitHub에서 찾을 수 있으며, 여기서 문제와 끌어오기 요청을 만들고 검토할 수도 있습니다. 자세한 내용은 참여자 가이드를 참조하세요.
.NET