Highlight hovered rows by default

Greetings,

We are trying to set some default behavior for grids using a class that inherits from RadzenDataGrid.

Is there a simple way to get rows to highlight when hovered?

In the examples, it's about binding the Value property to a list, but I can't figure out how to do that from this context...

public class SiteDataGrid<TItem> : RadzenDataGrid<TItem>
{
    public SiteDataGrid()
    {
        AllowAlternatingRows = false;
        AllowColumnResize = true;
        AllowFiltering = true;
        AllowSorting = true;
        FilterMode = FilterMode.CheckBoxList;
    }
}

Thanks,
Ben

Assigning RowSelect will do the same. Here is also how to bind Value in code:
Blazor University - Two-way binding.

1 Like

Thank you so much. This worked.

public class SiteDataGrid<TItem> : RadzenDataGrid<TItem>
{
    public SiteDataGrid()
    {
        AllowAlternatingRows = false;
        AllowColumnResize = true;
        AllowFiltering = true;
        AllowSorting = true;
        FilterMode = FilterMode.CheckBoxList;
        RowSelect = EventCallback.Factory.Create<TItem>(this, _ => { });
    }
}