Version

AfterDataNodesCollectionPopulated Event

Occurs after a TreeNodesCollection object is populated with bound data.
Syntax
'Declaration
 
Public Event AfterDataNodesCollectionPopulated As AfterDataNodesCollectionPopulatedEventHandler
public event AfterDataNodesCollectionPopulatedEventHandler AfterDataNodesCollectionPopulated
Event Data

The event handler receives an argument of type AfterDataNodesCollectionPopulatedEventArgs containing data related to this event. The following AfterDataNodesCollectionPopulatedEventArgs properties provide information specific to this event.

PropertyDescription
IsPrinting (Inherited from Infragistics.Win.UltraWinTree.DataNodesCollectionPopulatedEventArgs)Returns true if the nodes collection being populated is in a tree that is being used by an UltraTreePrintDocument for printing.
Nodes (Inherited from Infragistics.Win.UltraWinTree.DataNodesCollectionPopulatedEventArgs)Returns the TreeNodesCollection instance which is being initialized from the data source.
Example
Imports Infragistics.Win.UltraWinTree

    Private Sub ultraTree1_AfterDataNodesCollectionPopulated(ByVal sender As Object, ByVal e As Infragistics.Win.UltraWinTree.AfterDataNodesCollectionPopulatedEventArgs) Handles ultraTree1.AfterDataNodesCollectionPopulated
        ' This event fires after the tree has populated a Nodes collection
        ' with data from the data source. 
        ' Since the nodes collection has been populated with nodes at this point,
        ' This is an excellent place to autosize the columns based on their
        ' contents.
        Dim column As UltraTreeNodeColumn
        For Each column In e.Nodes.ColumnSetResolved.Columns
            column.PerformAutoResize(ColumnAutoSizeMode.AllNodesWithDescendants)
        Next
    End Sub
using Infragistics.Win.UltraWinTree;

private void ultraTree1_AfterDataNodesCollectionPopulated(object sender, Infragistics.Win.UltraWinTree.AfterDataNodesCollectionPopulatedEventArgs e)
		{
			// This event fires after the tree has populated a Nodes collection
			// with data from the data source. 
			// Since the nodes collection has been populated with nodes at this point,
			// this is an excellent place to autosize the columns based on their
			// contents.
			foreach (UltraTreeNodeColumn column in e.Nodes.ColumnSetResolved.Columns)
				column.PerformAutoResize(ColumnAutoSizeMode.AllNodesWithDescendants);
		}
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also