SplitContainer.Orientation SplitContainer.Orientation SplitContainer.Orientation SplitContainer.Orientation Property

정의

SplitContainer 패널이 가로 방향인지 아니면 세로 방향인지를 나타내는 값을 가져오거나 설정합니다.Gets or sets a value indicating the horizontal or vertical orientation of the SplitContainer panels.

public:
 property System::Windows::Forms::Orientation Orientation { System::Windows::Forms::Orientation get(); void set(System::Windows::Forms::Orientation value); };
public System.Windows.Forms.Orientation Orientation { get; set; }
member this.Orientation : System.Windows.Forms.Orientation with get, set
Public Property Orientation As Orientation

속성 값

Orientation 값 중 하나입니다.One of the Orientation values. 기본값은 Vertical입니다.The default is Vertical.

예외

할당된 값이 Orientation 값 중 하나가 아닌 경우The assigned value is not one of the Orientation values.

예제

다음 코드 예제에서는 가로 분할자 인 맨 위에 나타나며 아래쪽 패널 포함 ListView 컨트롤입니다.The following code example shows a horizontal splitter whose top and bottom panels contain ListView controls. 가로 분할자의 다른 기본 속성도 표시 됩니다.Other basic properties of a horizontal splitter are also shown. 이 예제는에 대해 제공 된 큰 예제의 일부는 SplitContainer 클래스입니다.This example is part of a larger example provided for the SplitContainer class.

// Basic SplitContainer properties.
// This is a horizontal splitter whose top and bottom panels are ListView controls. The top panel is fixed.
splitContainer2->Dock = System::Windows::Forms::DockStyle::Fill;

// The top panel remains the same size when the form is resized.
splitContainer2->FixedPanel = System::Windows::Forms::FixedPanel::Panel1;
splitContainer2->Location = System::Drawing::Point( 0, 0 );
splitContainer2->Name = "splitContainer2";

// Create the horizontal splitter.
splitContainer2->Orientation = System::Windows::Forms::Orientation::Horizontal;
splitContainer2->Size = System::Drawing::Size( 207, 273 );
splitContainer2->SplitterDistance = 125;
splitContainer2->SplitterWidth = 6;

// splitContainer2 is the third control in the tab order.
splitContainer2->TabIndex = 2;
splitContainer2->Text = "splitContainer2";

// Basic SplitContainer properties.
// This is a horizontal splitter whose top and bottom panels are ListView controls. The top panel is fixed.
splitContainer2.Dock = System.Windows.Forms.DockStyle.Fill;
// The top panel remains the same size when the form is resized.
splitContainer2.FixedPanel = System.Windows.Forms.FixedPanel.Panel1;
splitContainer2.Location = new System.Drawing.Point(0, 0);
splitContainer2.Name = "splitContainer2";
// Create the horizontal splitter.
splitContainer2.Orientation = System.Windows.Forms.Orientation.Horizontal;
splitContainer2.Size = new System.Drawing.Size(207, 273);
splitContainer2.SplitterDistance = 125;
splitContainer2.SplitterWidth = 6;
// splitContainer2 is the third control in the tab order.
splitContainer2.TabIndex = 2;
splitContainer2.Text = "splitContainer2";
' Basic SplitContainer properties.
' This is a horizontal splitter whose top and bottom panels are ListView controls. The top panel is fixed.
splitContainer2.Dock = System.Windows.Forms.DockStyle.Fill
' The top panel remains the same size when the form is resized.
splitContainer2.FixedPanel = System.Windows.Forms.FixedPanel.Panel1
splitContainer2.Location = New System.Drawing.Point(0, 0)
splitContainer2.Name = "splitContainer2"
' Create the horizontal splitter.
splitContainer2.Orientation = System.Windows.Forms.Orientation.Horizontal
splitContainer2.Size = New System.Drawing.Size(207, 273)
splitContainer2.SplitterDistance = 125
splitContainer2.SplitterWidth = 6
' splitContainer2 is the third control in the tab order.
splitContainer2.TabIndex = 2
splitContainer2.Text = "splitContainer2"

설명

사용 하 여는 Orientation 속성을 변경 합니다 SplitContainer 세로에서 가로로 또는 세로로 가로에서.Use the Orientation property to change the SplitContainer from vertical to horizontal or from horizontal to vertical.

적용 대상

추가 정보