Tooltip when text exceeds column width

4 posts, 0 answers
  1. Ronald
    Ronald avatar
    21 posts
    Member since:
    Dec 2007

    Posted 30 Jan 2013 Link to this post

    Hi,

    I received a request from a customer about showing tooltips on cells when the cell contents exceeds the size of the cell.
    Our windows forms client has that functionality using ms listview control. (See attached image.)

    In my Silverlight application I display a thumbnail of the document when hoovering over the first column, so I thought I could set the tooltip in the same section: GridViewCell.MouseEnter.

    In the MouseEnter handler I measure the width of the column and a temporary Textbox with the contents of the column. If it exceeded I set the tooltip. (Expecting some problems with datetime columns etc.)
    var tb = new TextBlock { Text = cell.Value.ToString() };
    if (tb.ActualWidth > cell.ActualWidth)
    {
     cell.SetValue(ToolTipService.ToolTipProperty, tb.Text);
     return;
    }
    cell.SetValue(ToolTipService.ToolTipProperty, null);

    And the result: No tooltip gets displayed, is there a way to accomplish this?

    Kind regards,
    Ronald
  2. Yoan
    Admin
    Yoan avatar
    1066 posts

    Posted 01 Feb 2013 Link to this post

    Hello Ronald,

    As it turns out, you can not achieve this functionality with the current implementation of RadGridView.

    Please excuse us for the inconvenience caused!


    Kind regards,
    Yoan
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. DevCraft banner
  4. Ronald
    Ronald avatar
    21 posts
    Member since:
    Dec 2007

    Posted 07 Feb 2013 Link to this post

    Hi,

    I'm using a popup control instead of the tooltipservice.
    And the customer is happy with this solution, so I'm also happy!

    Perhaps you can add this functionality in future releases of your nice products.

    Best regards,
    Ronald
  5. Yoan
    Admin
    Yoan avatar
    1066 posts

    Posted 08 Feb 2013 Link to this post

    Hello Ronald,

    I have added your question to our Public Issue Tracking System as a feature request. You can find the PITS Issue here: Public URL 


    There you may vote for it and you may follow its progress as well.

    All the best,
    Yoan
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top