# SetRootItems(IList<TreeViewItemData<T>>)

> Sets the root items.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine.UIElements](/engine/6000.7/script-reference/unityengine/uielements.md)
* **Assembly:** UnityEngine.UIElementsModule

```csharp
public void SetRootItems(IList<TreeViewItemData<T>> items)
```

### Parameters

**** (\[IList\<TreeViewItemData\<T>>]\(https\://learn.microsoft.com/dotnet/api/system.collections.generic.ilist-1)): The TreeView root items.

### Remarks

Root items can include their children directly.
