Tool tip Pop up on Mouse over on a Chart

4 posts, 0 answers
  1. kiran
    kiran avatar
    36 posts
    Member since:
    May 2008

    Posted 05 Jun 2008 Link to this post

    Hi,

    I need to show a tool tip pop up on mouse over on a chart.

    exact requirement is like:

    i have a Line chart with dates on X-axis and double values on Y-axis.

    In general on mouse over on any chart we will get tool tip which shows the value at that point.

    instead i need to show a pop up  kind of thing (like wise context menu/ Data table which has one column and multiple rows) on mouse over.which should  have 5 different data items which i need to get from XML/DataBase for that particular date where Mouse was currently placed.

    Can any one provide the approach to do this? is this possible with RadControls?
    If so please provide some sample application/ Code.

    Thanks in advance.

    regards,
    kiran

  2. Dwight
    Admin
    Dwight avatar
    475 posts

    Posted 06 Jun 2008 Link to this post

    Hello kiran,

    The following code demonstrates setting tooltip to the second Item of the first series:
    this.radChart1.Series[0].Items[1].ActiveRegion.Tooltip = "This is the second item in the first series."
     

    Should you have further questions, do not hesitate to write us.




    Kind regards,
    Evtim
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. UI for WinForms is Visual Studio 2017 Ready
  4. kiran
    kiran avatar
    36 posts
    Member since:
    May 2008

    Posted 26 Jun 2008 Link to this post

    Hi Evtim,

    The tool tip is not working for line chart. this is a major mishap for me . The following code i have used to show tool tip.
    i have drawn a line chart with datatable data binding. after that i added the following code:

    ChartSeriesItemsCollection items = this.radChart1.Series[1].Items;
    for (int i = 0; i < items.Count; i++)
    {
        items[i].ActiveRegion.Tooltip = items[i].YValue.ToString();
    }

    what is the problem in this code.
     
    I am in a big trouble now. Please help me out to get rid of this. Any help is highly appreciated.

    Please share some sample code or sample application if there is any way to resolve this.

    Regards,
    Kiran
  5. Dwight
    Admin
    Dwight avatar
    475 posts

    Posted 30 Jun 2008 Link to this post

    Hello kiran,

    Your code works fine, but you need to enable point marks for the line series:
    this.radChart1.Series[0].Appearance.PointMark.Visible = true
    this.radChart1.Series[0].Appearance.PointMark.FillStyle.FillType = Telerik.Charting.Styles.FillType.Solid; 
    this.radChart1.Series[0].Appearance.PointMark.FillStyle.MainColor = Color.Red; 
     

    Hope that helps.

    All the best,
    Evtim
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
Back to Top