Display another data on tooltip except category and value

13 posts, 0 answers
  1. Johnny
    Johnny avatar
    2 posts
    Member since:
    Jan 2012

    Posted 16 Mar 2012 Link to this post

    Hello,
    I want to display on tooltip another dataitems except the x category and y value. eg. i want to display in a timeplot how much monoey spends in some months, but i want to display on tooltip who spends the money and I icnlude who spends on json file, eg:

    [{
        "name" : "john" ,
        "amount" : 724456 ,
        "date" : "2012-02-05" 
      },
    {
        "name" : "Nick" ,
        "amount" : 290000 ,
        "date" : "2012-02-01" 
      } ]

    How can i display the "name" on tooltip, if the category is "date" and value is "amount"??
  2. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2622 posts

    Posted 19 Mar 2012 Link to this post

    Hello Vaf,

    You could customize the text of the tooltip using dataItem in the template.
    For example:
    tooltip: {
       ...
       template: "#= dataItem.employeeName #"
      }

    For convenience I created a sample project and attached it.


    Greetings,
    Iliana Nikolova
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  3. Johnny
    Johnny avatar
    2 posts
    Member since:
    Jan 2012

    Posted 19 Mar 2012 Link to this post

    Thanks for the answer!it's very useful!
  4. Neil
    Neil avatar
    39 posts
    Member since:
    May 2012

    Posted 10 May 2012 Link to this post

    Hey, So I`m trying to do the same with the tooltip - to display something in addition to the default tooltip.

    So default is that the tooltip displays the value of the point, I added to display the date like this:

    tooltip: {
                                visible: true,
                                format: "{0:N0}",
                                template: "#= dataItem.Date #"
                            }


    But then it only shows the date but not the value any more. Any advice ?

    Ideally I would like to see the name value and date in the tooltip.

    name being written when adding the series :   
     series:
                            [{
                                field: "Value1",
                                name: "GP3-PT-270517.PV_IND"
                            }, 
                            {
                            field: "Value2",
                            name: "Name2"
                            },

    .


    Interesting thing is that when i generate json file and the field name is "GP3-PT-270517.PV_IND" it doesnt work, hence i had to rename it to Value1, Value 2 and so on. Why is that ? json doesnt like " -, , ._" ?
  5. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2622 posts

    Posted 10 May 2012 Link to this post

    Hello Nail,

    I have already provided answers to your questions in this forum thread. Please check it and let me know if you need further assistance. 

    Greetings,

    Iliana Nikolova
    the Telerik team
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  6. osman
    osman avatar
    19 posts
    Member since:
    May 2013

    Posted 05 Jun 2013 Link to this post

    can i show another chart in tooltip box ? when hover point ? so can i write javascript into tooltip? is it possible?
  7. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2622 posts

    Posted 06 Jun 2013 Link to this post

    Hello Osman,

    In order to achieve this you could use a tooltip.template. 

    Regards,
    Iliana Nikolova
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  8. osman
    osman avatar
    19 posts
    Member since:
    May 2013

    Posted 13 Jun 2013 Link to this post

     I wanna Make Kendo Bar Chart (line chart ......) But I need to convert them for ex: 6032 second to 0 day ,0 hour ,10 minutes ,32 second (it shows in x direction or y direction) . how is it possible in kendo chart? Can Send me Any Example?
  9. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2622 posts

    Posted 14 Jun 2013 Link to this post

    Hello Osman,

    I am not quite sure if I understand your question correctly. Could you please provide more detailed information about the exact functionality you are trying to implement? This way I would be able to advice you further and provide concrete recommendations. Thank you in advance for your cooperation.
     
    Regards,
    Iliana Nikolova
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  10. osman
    osman avatar
    19 posts
    Member since:
    May 2013

    Posted 14 Jun 2013 Link to this post

    If You Look the My Attached Folder You Gonna Understand me
  11. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2622 posts

    Posted 19 Jun 2013 Link to this post

    Hi Osman,

    Thank you for the provided image in your last post. You could achieve this using valueAxis.lables.template - hence create a custom function which converts seconds in days, hours etc.

    Regards,
    Iliana Nikolova
    Telerik
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
  12. Javier
    Javier avatar
    16 posts
    Member since:
    Feb 2015

    Posted 09 Jun 2015 Link to this post

    This link is not working http://demos.kendoui.com/beta/dataviz/bar-charts/index.html
  13. Iliana Nikolova
    Admin
    Iliana Nikolova avatar
    2622 posts

    Posted 12 Jun 2015 Link to this post

    Hi Javier,

    The correct link is http://demos.telerik.com/kendo-ui/beta/bar-charts/index.

    Regards,
    Iliana Nikolova
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
Back to Top