DataGridTableStyle.RowHeaderWidth Property
Gets or sets the width of row headers.
Namespace: System.Windows.Forms
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
When row headers are visible a plus sign is displayed in each row header if the underlying data has a related child table.
This property will not function until you add DataGridTableStyle objects to the GridTableStylesCollection. Until then, setting this property will have no effect.
The following code example demonstrates the use of this member.
private void CallEventLoader() { this.Load += new EventHandler( this.DataGridTableStyle_RowHeaderWidth_Load); } public void AttachRowHeaderWidthChanged() { myDataGridTableStyle.RowHeaderWidthChanged += new EventHandler(MyDelegateRowHeaderChanged); } private void MyDelegateRowHeaderChanged(object sender, EventArgs e) { MessageBox.Show("Row header width is changed"); } private void button1_Click(object sender, System.EventArgs e) { myDataGridTableStyle.RowHeaderWidth = 30; } private void button2_Click(object sender, System.EventArgs e) { MessageBox.Show("Row header width is: " + myDataGridTableStyle.RowHeaderWidth); }
Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.