DataGridParentRowsLabelStyle 열거형
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
주의
DataGrid is provided for binary compatibility with .NET Framework and is not intended to be used directly from your code. Use DataGridView instead.
DataGrid 컨트롤의 부모 행 레이블을 표시하는 방법을 지정합니다.
public enum class DataGridParentRowsLabelStyle
public enum DataGridParentRowsLabelStyle
[System.ComponentModel.Browsable(false)]
[System.Obsolete("`DataGrid` is provided for binary compatibility with .NET Framework and is not intended to be used directly from your code. Use `DataGridView` instead.", false, DiagnosticId="WFDEV006", UrlFormat="https://aka.ms/winforms-warnings/{0}")]
public enum DataGridParentRowsLabelStyle
type DataGridParentRowsLabelStyle =
[<System.ComponentModel.Browsable(false)>]
[<System.Obsolete("`DataGrid` is provided for binary compatibility with .NET Framework and is not intended to be used directly from your code. Use `DataGridView` instead.", false, DiagnosticId="WFDEV006", UrlFormat="https://aka.ms/winforms-warnings/{0}")>]
type DataGridParentRowsLabelStyle =
Public Enum DataGridParentRowsLabelStyle
- 상속
- 특성
필드
| Name | 값 | Description |
|---|---|---|
| None | 0 | 부모 행 레이블을 표시하지 않습니다. |
| TableName | 1 | 부모 테이블 이름을 표시합니다. |
| ColumnName | 2 | 부모 열 이름을 표시합니다. |
| Both | 3 | 부모 테이블과 열 이름을 모두 표시합니다. |
예제
다음 예제에서는 가능한 각 값을 DataGridParentRowsLabelStyle반복합니다.
Private Sub ChangeParentRowLabels(ByVal myGrid As DataGrid)
Static currentLabelStyle As Integer
If currentLabelStyle = 4 Then currentLabelStyle = 0
Select Case currentLabelStyle
Case 0
myGrid.ParentRowsLabelStyle = DataGridParentRowsLabelStyle.None
Case 1
myGrid.ParentRowsLabelStyle = DataGridParentRowsLabelStyle.TableName
Case 2
myGrid.ParentRowsLabelStyle = DataGridParentRowsLabelStyle.ColumnName
Case 3
myGrid.ParentRowsLabelStyle = DataGridParentRowsLabelStyle.Both
Case Else
myGrid.ParentRowsLabelStyle = DataGridParentRowsLabelStyle.Both
End Select
' Increment the variable.
currentLabelStyle+=1
End Sub
설명
이 열거형의 멤버를 사용하여 속성 값을 ParentRowsLabelStyle 설정합니다.
부모 행은 1-1 DataRelation 초 DataTable이상 포함된 경우 DataGrid 와 속성이 탐색을 허용하는 값으로 설정된 경우에만 AllowNavigation 표시할 수 있습니다.