Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
125
guide with linear charts
posted

Hello I will need guide to make this graph

The code to create this Line chart.

I tried by myself but I got stuck at some points.

I need to do this>

On  step 1) Is just an image waiting to drag a parameter

( object that is constantly updating )

2) when a parameter is dragged then I had to create a legend and I subscribe to an event parameter.Updated

At this point I tried to create an empty serie for this parameter (blue)

 

3) on Parameter Updated I get a new value pair of this parameter (eg: (12:34 hh:mm, 90%))

On this event I have to add this point (pair) to the serie corresponding to the parameter.

Then I will have to remove old points of the serie ( I will always have the ones in the range between max and min hours:min)

When  time pass I will have to change the time range

 

This is some info constantly updated, there is a subscription for each parameter and at the update one new point is added, and an old one is removed.

Could be up to 20 series

 

I hope you understand and can guide me..

thank you very much

Parents
  • 53790
    posted

    Hello facundomensajes,

    facundomensajes said:
    The code to create this Line chart

    Please upload again your code, because we didn`t receive it.

    facundomensajes said:
    1) Is just an image waiting to drag a parameter

    I`m not sure that I understand well your requirement, but you could create your chart with empty data and using multiple threads you could add new points.

    facundomensajes said:
    ... when a parameter is dragged then I had to create a legend...

     You could use the the code below to create your legend:

    CompositeLegend myLegend = new CompositeLegend();

    myLegend.ChartLayers.Add(myScatterLayer);

    myLegend.Bounds =new Rectangle(88, 2, 11, 15);

    myLegend.BoundsMeasureType =MeasureType.Percentage;

    myLegend.PE.ElementType =PaintElementType.Gradient;

    myLegend.PE.FillGradientStyle =GradientStyle.ForwardDiagonal;

    myLegend.PE.Fill =Color.CornflowerBlue;

    myLegend.PE.FillStopColor =Color.Transparent;

    myLegend.Border.CornerRadius = 10;

    myLegend.Border.Thickness = 1;

    this.ultraChart1.CompositeChart.Legends.Add(myLegend);

     

    facundomensajes said:
    3) on Parameter Updated I get a new value pair of this parameter. On this event I have to add this point (pair) to the serie corresponding to the parameter. Then I will have to remove old points of the serie
    Please take a  look at the attached sample with similar behavior.

    Let me know if you have any questions.

     

    ScatterChartWithLineThreads.zip
Reply Children