New to Telerik UI for .NET MAUI? Start a free 30-day trial

Migrating the TreeView from Xamarin.Forms to .NET MAUI

The Telerik UI for .NET MAUI TreeView control has been designed and built from the ground up as a new control with a new API and significant improvements over its Xamarin counterpart.

The tables in the following sections list the differences between the APIs of the Xamarin.Forms TreeView and .NET MAUI TreeView.

Namespaces Differences

When migrating the TreeView from Xamarin to .NET MAUI, consider the following differences in the namespaces:

Control Control name XAML Namespcace C# Namespace
Xamarin TreeView RadTreeView xmlns:telerikDataControls="clr-namespace:Telerik.XamarinForms.DataControls;assembly=Telerik.XamarinForms.DataControls" using Telerik.XamarinForms.DataControls;
.NET MAUI TreeView RadTreeView xmlns:telerik=""` using Telerik.Maui.Controls;

API Differences

When migrating the TreeView from Xamarin to .NET MAUI, consider the following differences in the API:

Xamarin TreeView .NET MAUI TreeView
NA HorizontalScrollBarVisibility
NA HorizontalScrollBarLayoutMode
NA VerticalScrollBarVisibility
NA VerticalScrollBarLayoutMode
SelectedItems Collection(read-only) SelectedItems Collection
NA SelectedItem
NA SelectionMode - None, Single, Multiple
CheckedItemsCollection(read-only) CheckedItemsCollection
CheckBoxModes- None, Individual, Propagate CheckBoxModes - None,Independent,Recursive
ItemTemplate (applies on TreeViewDescriptor level) ItemTemplate (applies on TreeView level), ItemTemplate (applies on TreeViewDescriptor level)
LoadOnDemand NA
ScrollItemIntoView() ScrollTo()
NA ItemsSourceChanged event
SelectionChanged SelectionChanged
ItemTapped event ItemTapped event
ItemHold event NA
ItemCollapsed event NA
ItemExpanded event NA
Commands - ItemTap, ItemHold, ItemCollapse,ItemExpand,LoadOnDemand,Unknown NA
NA ExpandAll command
NA CollapseAll command
NA CheckAll command
NA UnCheckAll command
NA ScrollToCommand command
ExpandAll() ExpandAll()
ExpandAll() CollapseAll()
Expand() NA
Collapse() NA
NA CheckAlll()
NA UnCheckAll()
CheckItem() NA
UncheckItem() NA
ItemStyle (applies on TreeView level) ItemStyle (applies on TreeView level), ItemStyle (applies on TreeViewDescriptor level)
ItemStyleSelector (applies on TreeView level) ItemStyleSelector (applies on TreeView level), ItemStyleSelector (applies on TreeViewDescriptor level)

See Also

In this article