DesignerAutoFormat.Name 속성
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
개체의 DesignerAutoFormat 이름을 가져옵니다.
public:
property System::String ^ Name { System::String ^ get(); };
public string Name { get; }
member this.Name : string
Public ReadOnly Property Name As String
속성 값
이름입니다 DesignerAutoFormat .
예제
다음 코드 예제에서는 개체의 속성을 재정 AutoFormats 의 ControlDesigner 하여 컬렉션에 세 개의 명명된 형식을 만들고 추가하는 방법을 보여 줍니다.
// The collection of AutoFormat objects for the IndentLabel object
public override DesignerAutoFormatCollection AutoFormats
{
get
{
if (_autoFormats == null)
{
// Create the collection
_autoFormats = new DesignerAutoFormatCollection();
// Create and add each AutoFormat object
_autoFormats.Add(new IndentLabelAutoFormat("MyClassic"));
_autoFormats.Add(new IndentLabelAutoFormat("MyBright"));
_autoFormats.Add(new IndentLabelAutoFormat("Default"));
}
return _autoFormats;
}
}
' The collection of AutoFormat objects for the IndentLabel object
Public Overrides ReadOnly Property AutoFormats() As DesignerAutoFormatCollection
Get
If _autoFormats Is Nothing Then
' Create the collection
_autoFormats = New DesignerAutoFormatCollection()
' Create and add each AutoFormat object
_autoFormats.Add(New IndentLabelAutoFormat("MyClassic"))
_autoFormats.Add(New IndentLabelAutoFormat("MyBright"))
_autoFormats.Add(New IndentLabelAutoFormat("Default"))
End If
Return _autoFormats
End Get
End Property
설명
Visual Studio 2005와 같은 비주얼 디자이너는 컬렉션에 있는 AutoFormats 각 DesignerAutoFormat 개체의 ControlDesigner 속성을 사용하여 Name 사용 가능한 자동 스타일 형식 목록을 만듭니다.