Profile Picture

NHeatMapSeries combined with NLineSeries

Posted By joern kunze 6 Years Ago
Author
Message
joern kunze
Problem Posted 6 Years Ago
View Quick Profile
Junior Member

Junior Member (13 reputation)Junior Member (13 reputation)Junior Member (13 reputation)Junior Member (13 reputation)Junior Member (13 reputation)Junior Member (13 reputation)Junior Member (13 reputation)Junior Member (13 reputation)Junior Member (13 reputation)

Group: Forum Members
Last Active: 4 Months Ago
Posts: 86, Visits: 221
Hello Experts,

I have a NHeatMapSeries which looks like:
https://www.nevron.com/forum/uploads/images/13e3edb2-0b81-4adf-bf7b-ed89.jpg
So far so good. But now I want to add a line with a anchored CallOut-Label at y=5:

   NLineSeries line = (NLineSeries)_oChart.Series.Add(SeriesType.Line);
    line.Name = "ReferenceLine";
    line.UseXValues = true;
    line.MarkerStyle.Visible = false;
    line.DataLabelStyle.Visible = false;
    line.InflateMargins = false;
    line.BorderStyle.Color = oLine.Color;
    line.BorderStyle.Width = new NLength(oLine.Thickness, NPointGraphicsUnit.Point);
    line.Values.AddRange(oLine.YValues);
line.XValues.AddRange(oLine.XValues);
     // Create a rounded rect callout 
      NRectangularCallout m_RectangularCallout = new NRectangularCallout();
      int iLabelPos = 8; 
     ...
     // Anchor the callout to data point #0 of the line series
      NDataPointAnchor anchor = new NDataPointAnchor(line, 1, ContentAlignment.MiddleCenter, StringAlignment.Center);
      m_RectangularCallout.Anchor = anchor;
      m_RectangularCallout.AlwaysInsideParent = true; 
_NevronChart.Panels.Add(m_RectangularCallout);

Result: The Callout label is plotted (see picture lower right: label with green back colour)- but no line is plotted. The very same approach does work for Point- and Line plots though. What must be done to make it working with NHeatMapSeries ?

Thanks for the help,
best regards,
Joern







Similar Topics


Reading This Topic