This is a migrated thread and some comments may be shown as answers.

Add kendoTooltip for every cell in the grid

1 Answer 108 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Edward
Top achievements
Rank 1
Edward asked on 29 Jan 2019, 03:51 AM

What would be easiest way to do this..?

Would it represent a performance hit (for grid with 25 columns)?

1 Answer, 1 is accepted

Sort by
0
Georgi
Telerik team
answered on 30 Jan 2019, 02:58 PM
Hi Edward,

A possible solution is to add a title attributes to the cells and simply initialize a Tooltip widget over the element of the grid.

e.g.

// grid
 
@(Html.Kendo().Grid<Student>()
        .Name("grid")
        .Columns(columns =>
        {
            columns.Bound(x => x.FirstName).HtmlAttributes(new { title="some tooltip content"});
 
 
// tooltip initialization
 
<script>
    $(function () {
        $('#grid').kendoTooltip({
            filter: "td"
        });
    })
</script>

The above configuration will display a tooltip with content the title of the cell when the user hovers the corresponding td element.


Regards,
Georgi
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
Grid
Asked by
Edward
Top achievements
Rank 1
Answers by
Georgi
Telerik team
Share this question
or