Occurs when the Header's height is changed.

Namespace: Dapfor.Net.Ui
Assembly: Dapfor.Net (in Dapfor.Net.dll) Version: 2.10.3.24917 (2.10.3.24917)

Syntax

C#
public event EventHandler<GridHeaderEventArgs> HeaderHeightChanged
Visual Basic
Public Event HeaderHeightChanged As EventHandler(Of GridHeaderEventArgs)
Visual C++
public:
 event EventHandler<GridHeaderEventArgs^>^ HeaderHeightChanged {
	void add (EventHandler<GridHeaderEventArgs^>^ value);
	void remove (EventHandler<GridHeaderEventArgs^>^ value);
}
F#
member HeaderHeightChanged : IEvent<EventHandler<GridHeaderEventArgs>,
    GridHeaderEventArgs>

Value

Type: System..::..EventHandler<(Of <(<'GridHeaderEventArgs>)>)>

Examples

 Copy imageCopy
public void InitializeGrid(Grid grid)
{
    grid.HeaderAdded += delegate(object sender, GridHeaderEventArgs e)
    {
        Console.WriteLine("A header has been added on the {0} hierarchical level", e.Header.Level);
    };

    grid.HeaderRemoving += delegate(object sender, GridHeaderEventArgs e)
    {
        Console.WriteLine("A header is removing from the {0} hierarchical level", e.Header.Level);
    };

    grid.HeaderRemoved += delegate(object sender, GridHeaderEventArgs e)
    {
        Console.WriteLine("A header has been removed from the grid");
    };

    grid.HeaderHeightChanged += delegate(object sender, GridHeaderEventArgs e)
    {
        Console.WriteLine("The new height of the header = {0}", e.Header.Height);
    };

    //Add header and some columns
    grid.Headers.Add(new Header());
    grid.Headers[0].Add(new Column("Price"));
    grid.Headers[0].Add(new Column("Quantity"));
    grid.Headers.Add(new Header());

    //Set a new height of the column panel
    grid.Headers[0].ColumnPanelHeight = 25;

    //Hide the header
    grid.Headers[1].Visible = false;

    //Move the first column
    grid.Headers[0]["Price"].VisibleIndex = 1;

    //Remove the header
    grid.Headers.RemoveAt(0);
}

Thread Safety

This event is always raised in the GUI thread

See Also