windowsforms-devexpress-dot-xtratreelist-dot-columns-dot-treelistcolumn-e5b85b4b.md
Gets or sets a column’s position within the Tree List’s column collection.
Namespace : DevExpress.XtraTreeList.Columns
Assembly : DevExpress.XtraTreeList.v25.2.dll
NuGet Packages : DevExpress.Win.Navigation, DevExpress.Win.TreeList
[Browsable(false)]
public int AbsoluteIndex { get; set; }
<Browsable(False)>
Public Property AbsoluteIndex As Integer
| Type | Description |
|---|---|
| Int32 |
An integer value representing the column’s zero based index within the collection.
|
Use this property to obtain the column’s position within the collection or to move it to a new position. Note that this doesn’t affect the column’s visible position within the Tree List. To change the column’s position among other visible columns, use its TreeListColumn.VisibleIndex property.
You can access a column by its absolute index using the Tree List’s TreeList.Columns indexer. Absolute indexes are also returned by the column collection’s TreeListColumnCollection.IndexOf method.
The next example demonstrates how to access a focused node value in the column which is identified by the TreeListColumn.AbsoluteIndex property set to 0.
Two ways are provided to perform this operation: via the TreeListNode.Item property and TreeListNode.SetValue method.
//first method
treeList1.FocusedNode.SetValue(0, "new value");
//second method
treeList1.FocusedNode[0] = "new value";
'first method
TreeList1.FocusedNode.SetValue(0, "new value")
'second method
TreeList1.FocusedNode(0) = "new value"
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the AbsoluteIndex property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
zip-compression-and-archive-api-examples/CS/CompressionLibraryExamples/MyTreeData.cs#L33
VirtualTreeGetCellValueInfo info) {
info.CellData = cellsCore[info.Column.AbsoluteIndex];
}
zip-compression-and-archive-api-examples/VB/CompressionLibraryExamples/MyTreeData.vb#L33
Private Sub VirtualTreeGetCellValue(ByVal info As VirtualTreeGetCellValueInfo) Implements TreeList.IVirtualTreeListData.VirtualTreeGetCellValue
info.CellData = cellsCore(info.Column.AbsoluteIndex)
End Sub
See Also