Trying to add a tooltip to a grid

2 posts, 0 answers
  1. Jeffrey
    Jeffrey avatar
    3 posts
    Member since:
    Mar 2014

    Posted 20 Mar 2014 Link to this post

    I cant seem to figure out how to get the value from a hidden column in a kendo grid so that I can then pass it to a call  that will return a partial view.  Any help would be greatly appreciated.

    Here is the code for my grid.

                      .CellAction(cell =>

                          if (cell.Column.Title.Equals("   "))
                              switch (cell.DataItem.LEO_Availability)
                                  case 0:
                                      cell.HtmlAttributes["class"] = "dataFreeBtn";
                                  case 1:
                                      cell.HtmlAttributes["class"] = "dataAssignedBtn";
                                  case 2:
                                      cell.HtmlAttributes["class"] = "dataNondutyBtn";
                      .Columns(columns =>
                          columns.Bound(r => r.LEO_OfficerID).Hidden(true);
                          columns.Bound(r => r.LEO_Availability).Title("   ").Width(25);
                          columns.Bound(r => r.FullName).Title("Officer");
                          columns.Bound(r => r.LEO_CallSign).Title("Call Sign");
                          columns.Bound(r => r.LEO_PostName).Title("Post");

                    .LoadContentFrom("GetToolTipData", "DailyLog")
                    .Events(events => events.RequestStart("requestStart"))
                <script type="text/javascript">
                    function requestStart(e) {
                        var id ="tr").find("td:eq(0)").text();
  2. Atanas Korchev
    Atanas Korchev avatar
    8462 posts

    Posted 24 Mar 2014 Link to this post

    Hello Jeffrey,

    You should use to the the DOM element which the user has hovered (which corresponds to the grid table row). Then pass the text to your partial view via Here is some sample code:

        function requestStart(e) {
            var id ="td:eq(0)").text();
   = {
                id: id

    Atanas Korchev

    Build cross-platform mobile apps using Visual Studio and .NET. Register for the online webinar on 03/27/2014, 11:00AM US ET.. Seats are limited.

  3. UI for ASP.NET AJAX banner
Back to Top