jQuery UI Widgets Forums Chart toolTipFormatFunction

Tagged: 

This topic contains 2 replies, has 2 voices, and was last updated by  mrezzonico 4 years, 5 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • toolTipFormatFunction #111746

    mrezzonico
    Participant

    Sorry if I come with another problem but I am evaluating this product in order to see if I can do all I need.

    I have a chart with multiple lines series: series[0], series[1], series[2], series[3], …
    Each serie has his dataAdapter: dataAdapters[0], dataAdapters[1], dataAdapters[2], dataAdapters[3], …
    And I have only one toolTipFormatFunction for all the series.

    In the toolTipFormatFunction I need to access to some additional information in the serie records:
    If I am displaying the toolTip for series[0], then I need to print dataAdapters[0].records[itemIndex].addition_information
    If I am displaying the toolTip for series[1], then I need to print dataAdapters[1].records[itemIndex].addition_information
    If I am displaying the toolTip for series[2], then I need to print dataAdapters[2].records[itemIndex].addition_information
    If I am displaying the toolTip for series[3], then I need to print dataAdapters[3].records[itemIndex].addition_information

    The problem is:
    how can I know the name of the dataAdapter of the serie for which I am displaying the toolTip ?

    Thanks for any help
    Miche

    toolTipFormatFunction #111757

    admin
    Keymaster

    Hi mrezzonico,

    To access the dataAdapter you can use var dataAdapter = $(“#chart”).jqxChart(“source”);. Then dataAdapter.records[0] is the first record in the adapter.

    Hope this points you in the right direction.

    Regards,
    Peter

    toolTipFormatFunction #111799

    mrezzonico
    Participant

    Hi Peter,

    thanks a lot for your help.
    I will try it.

    Regards
    Miche

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.