ManagementTabPage クラス
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
一連のタブ ページ内の 1 つのタブ ページを表します。
public ref class ManagementTabPage : System::Windows::Forms::TabPage
public class ManagementTabPage : System.Windows.Forms.TabPage
type ManagementTabPage = class
inherit TabPage
Public Class ManagementTabPage
Inherits TabPage
- 継承
-
ManagementTabPage
例
次の例では、 クラスのメソッドとプロパティを ManagementTabPage 実装します。 この例では、プロパティの変更、カスタム プロパティの作成、およびカスタム CreateParams メソッドの作成をRightToLeftLayout可能にするコントロールを含むタブ ページをOnRightToLeftChanged作成します。 ウィザード ページが オブジェクトに WizardForm 配置されます。
using System;
using System.Windows.Forms;
using Microsoft.Web.Management.Client.Win32;
namespace ExtensibilityDemo
{
public partial class PageManagementTabPage : WizardPage
{
public PageManagementTabPage()
{
InitializeComponent();
// Set the initial label1 text to the RightToLeftLayout value.
label1.Text = this.ManagementTabPage1.RightToLeftLayout.ToString();
Caption = "ManagementTabPage";
}
// This is the modificationpage page. You can navigate to the previous page.
protected override bool CanNavigatePrevious
{
get
{
return true;
}
}
// Create the customized OnRightToLeftChanged method.
protected override void OnRightToLeftChanged(EventArgs e)
{
ShowMessage("Management tab page RightToLeftLayout changed");
}
// Create the customized CreateParams property.
protected override CreateParams CreateParams
{
get
{
const int WS_EX_LAYOUTRTL = 0x400000;
const int WS_EX_NOINHERITLAHYOUT = 0x100000;
CreateParams CP;
CP = base.CreateParams;
CP.ExStyle = CP.ExStyle | WS_EX_LAYOUTRTL | WS_EX_NOINHERITLAHYOUT;
return CP;
}
}
// The Change RightToLeftLayout button is clicked.
private void button1_Click(object sender, EventArgs e)
{
this.ManagementTabPage1.RightToLeftLayout = !this.ManagementTabPage1.RightToLeftLayout;
OnRightToLeftChanged(e);
label1.Text = this.ManagementTabPage1.RightToLeftLayout.ToString();
}
// The CreateParams button is clicked.
private void button2_Click(object sender, EventArgs e)
{
label2.Text = this.CreateParams.ToString();
}
}
}
private void InitializeComponent()
{
this.tabControl1 = new System.Windows.Forms.TabControl();
this.ManagementTabPage1 = new Microsoft.Web.Management.Client.Win32.ManagementTabPage();
this.label1 = new System.Windows.Forms.Label();
this.button1 = new System.Windows.Forms.Button();
this.ManagementTabPage2 = new Microsoft.Web.Management.Client.Win32.ManagementTabPage();
this.label2 = new System.Windows.Forms.Label();
this.button2 = new System.Windows.Forms.Button();
this.tabControl1.SuspendLayout();
this.ManagementTabPage1.SuspendLayout();
this.ManagementTabPage2.SuspendLayout();
this.SuspendLayout();
//
// tabControl1
//
this.tabControl1.Controls.Add(this.ManagementTabPage1);
this.tabControl1.Controls.Add(this.ManagementTabPage2);
this.tabControl1.Location = new System.Drawing.Point(15, 21);
this.tabControl1.Name = "tabControl1";
this.tabControl1.SelectedIndex = 0;
this.tabControl1.Size = new System.Drawing.Size(526, 164);
this.tabControl1.TabIndex = 0;
//
// ManagementTabPage1
//
this.ManagementTabPage1.Controls.Add(this.label1);
this.ManagementTabPage1.Controls.Add(this.button1);
this.ManagementTabPage1.Location = new System.Drawing.Point(4, 22);
this.ManagementTabPage1.Name = "ManagementTabPage1";
this.ManagementTabPage1.RightToLeftLayout = false;
this.ManagementTabPage1.Size = new System.Drawing.Size(518, 138);
this.ManagementTabPage1.TabIndex = 1;
this.ManagementTabPage1.Text = "ManagementTabPage1";
this.ManagementTabPage1.UseVisualStyleBackColor = true;
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(121, 57);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(35, 13);
this.label1.TabIndex = 2;
this.label1.Text = "label1";
//
// button1
//
this.button1.Location = new System.Drawing.Point(21, 25);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(164, 23);
this.button1.TabIndex = 3;
this.button1.Text = "Change right to left layout";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// ManagementTabPage2
//
this.ManagementTabPage2.Controls.Add(this.label2);
this.ManagementTabPage2.Controls.Add(this.button2);
this.ManagementTabPage2.Location = new System.Drawing.Point(4, 22);
this.ManagementTabPage2.Name = "ManagementTabPage2";
this.ManagementTabPage2.RightToLeftLayout = false;
this.ManagementTabPage2.Size = new System.Drawing.Size(518, 138);
this.ManagementTabPage2.TabIndex = 4;
this.ManagementTabPage2.Text = "ManagementTabPage2";
this.ManagementTabPage2.UseVisualStyleBackColor = true;
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(143, 70);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(35, 13);
this.label2.TabIndex = 5;
this.label2.Text = "label2";
//
// button2
//
this.button2.Location = new System.Drawing.Point(62, 23);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(164, 23);
this.button2.TabIndex = 6;
this.button2.Text = "Create Params";
this.button2.UseVisualStyleBackColor = true;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// PageManagementTabPage
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.tabControl1);
this.Name = "PageManagementTabPage";
this.Size = new System.Drawing.Size(560, 200);
this.tabControl1.ResumeLayout(false);
this.ManagementTabPage1.ResumeLayout(false);
this.ManagementTabPage1.PerformLayout();
this.ManagementTabPage2.ResumeLayout(false);
this.ManagementTabPage2.PerformLayout();
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.TabControl tabControl1;
private Microsoft.Web.Management.Client.Win32.ManagementTabPage ManagementTabPage1;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Button button1;
private Microsoft.Web.Management.Client.Win32.ManagementTabPage ManagementTabPage2;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Button button2;
注釈
オブジェクトは ManagementTabPage 、オブジェクト内のオブジェクトの System.Windows.Forms.TabControl コントロールのコレクションを WizardPage グループ化します。 このコントロールは オブジェクトに System.Windows.Forms.TabPage 似ています。
コンストラクター
ManagementTabPage() |
ManagementTabPage クラスの新しいインスタンスを初期化します。 |
プロパティ
CreateParams |
管理パネルの作成時に必要な作成パラメーターを取得します。 |
RightToLeftLayout |
右から左へのミラー配置が有効かどうかを示す値を取得または設定します。 |
メソッド
OnRightToLeftChanged(EventArgs) |
プロパティが変更されたときにアクションを実行するメカニズムを RightToLeftLayout 提供します。 |