How to implement dynamic tooltip?

9 posts, 0 answers
  1. Ryan C
    Ryan C avatar
    28 posts
    Member since:
    Aug 2009

    Posted 16 Oct 2009 Link to this post

    How would you go about creating dynamic tooltips such as the ones found here:
    http://freelance.geekinterview.com/143141-issues-with-jquery-cluetip.html

    Basically I got a glossary table in my database with definitions that I want to display as a tooltip in my aspx (c#) pages wherever the a keyword will match that of the glossary..

    Something basic will do, such as:
    http://plugins.learningjquery.com/cluetip/demo/

  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 19 Oct 2009 Link to this post

    Hello Ryan,

    You can refer to the following online demos which illustrate with examples different scenarios of displaying RadToolTips. Probably this should help you get started:
    RadToolTip
    Tooltipify Specific Area

    Thanks
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Ryan C
    Ryan C avatar
    28 posts
    Member since:
    Aug 2009

    Posted 19 Oct 2009 Link to this post

    Thanks. Was wondering if Telerik had something ready. I can try to develop something myself, but I'm predicting that I will have a performance issue.
  5. Svetlina Anati
    Admin
    Svetlina Anati avatar
    2795 posts

    Posted 21 Oct 2009 Link to this post

    Hi Ryan C,

    The RadToolTip provides functionality which offers dynamic creation of tooltips both on the server and on the client.

    1) To create a RadToolTip on the server you should use the standard approach you use to dynamically create controls, e.g :


    RadToolTip tooltip = new RadToolTip();
    tooltip.TargetControlID = myTargetControlID;
    //set different properties here
    this.form1.Controls.add(tooltip);

    2) To create a tooltip on the client you should use the RadToolTipManager's client API and its createToolTip() method which demonstrated in the demo below:

    http://demos.telerik.com/aspnet-ajax/tooltip/examples/radtooltipmanagerclientapi/defaultcs.aspx

    Since there is ability to create and configure tooltips both on the server and on the client and also to configure them, we believe that this is teh basic needed functionality a control should offer as a built-in functionality. If you expect another built-in functionality, please provide detailed explanations and in case we fpund it useful in enough scenarios and basic enough, we can consider it as a feature request and we can implement it.

    Sincerely yours,
    Svetlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  6. Ryan C
    Ryan C avatar
    28 posts
    Member since:
    Aug 2009

    Posted 21 Oct 2009 Link to this post

    Thanks for the detailed reply. It is still not straight forward as I hoped it to be.

    For future releases the explanation of what I wanted can be read below:

    For dynamic websites I usually serve one template aspx page which shows the content from the database by passing on the id of that content. The administrator of the site can manipulate the content as he/she likes through a custom page using the HTML editor.
    Now in this particular case this website also has a glossary, which the terms & definitions is being manipulated onto a table in the database. What I was looking for is to display a tooltip for each term matching the glossary on the page dynamically.

  7. Svetlina Anati
    Admin
    Svetlina Anati avatar
    2795 posts

    Posted 26 Oct 2009 Link to this post

    Hi Ryan C,

    As far as I understand your scenario is too specific to implement it as an embedded functionality. Furthermore you are the first one who has such a request for a feature. The controls offer a very rich API which provides teh ability to implement a lot of particular scenarios and we do not intend to implement so specific functionality if we do not have a lot of customers requests.

    Please, use the API of the control to achieve what you need and in case you experience problems, do not hesitate to contact us again!

    Greetings,
    Svetlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  8. dimiter
    dimiter avatar
    6 posts
    Member since:
    Apr 2007

    Posted 27 Oct 2009 Link to this post

    Hi Svetlina

    I am trying to create tooltip dynamically, but I failed an exception was thrown 
    Script control 'TT_1' is not a registered script control. Script controls must be registered using RegisterScriptControl() before calling RegisterScriptDescriptors().

    here is my code maybe i am wrong:

    Telerik.Web.UI.RadToolTip TT =

    new Telerik.Web.UI.RadToolTip();

     

    TT.Width = 240;

    TT.Height = 130;

    TT.OffsetX = 5;

    TT.Style.Add(

    "background", "url(../../App_Themes/Theme_1280/Images/tooltip.jpg) no-repeat");

     

    TT.TargetControlID =

    "cell_1" ;

     

    TT.Position = Telerik.Web.UI.ToolTipPosition.MiddleRight;

    TT.HideEvent = Telerik.Web.UI.ToolTipHideEvent.LeaveTargetAndToolTip;

    TT.ID =

    "TT_1" ;

     

    TT.Controls.Add(table);

    Cell.Controls.Add(TT);

     

    greetings
    Dimiter

     

  9. Svetlina Anati
    Admin
    Svetlina Anati avatar
    2795 posts

    Posted 29 Oct 2009 Link to this post

    Hello dimiter,

    The only thing I can assume without having your code is that you have missed to declare a ScriptManager before teh tooltip is added to the page. If so, please note that script controls should be registered in the ScriptManager and this is the most probable reason for this error. Another option is that you are adding the tooltip in some event which is not suitable considering the page lifecycle but I cannot tell you the exact reason until I am able to see what is actually goind on.

    This being said, if the problem persists, please provide code on base of which a fully runnable reproduction page could be created and I will do my best to help.

    Best wishes,
    Svetlina
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  10. Royce
    Royce avatar
    1 posts
    Member since:
    May 2013

    Posted 04 May 2013 Link to this post


    For display custom tooltip on custom dropdown, get the help from following link. I hope it resolve your problem

    http://www.mindstick.com/Articles/30062a03-ee92-40bb-bb7e-d9be0a666855/?Dynamic%20Tooltip%20on%20Custom%20Dr
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017