New to Telerik UI for ASP.NET MVC? Start a free 30-day trial
Capturing Row Hover Event оf Grid Row and Getting Data Item
Environment
Product | Grid for ASP.NET ASP.NET MVC |
Version | 2024.2.514 |
Description
How to capture the hover event of a row in the Grid and access the corresponding data item object?
Solution
To achieve row hover functionality and retrieve column object values, follow these steps:
- Subscribe to the
DataBound
event of the Grid. - Within the event handler, bind the jQuery
mouseenter
event to the table rows. - Use the
dataItem()
client-side method of the Grid to get the data item associated with the hovered row.
Razor
.Events(e => e.DataBound("onDataBound"))
REPL Example
You can test this example using the following REPL sample: Row Hover Event Example.