I am displaying multiple circular gauges on the iPad. I would like to be able to set the color of the border of the gauge (and perhaps the border width) in code to draw attention to some of the gauges. Is there a built in way to do this?
Alternatively - is there a way to change the color of the gauge itself?
Is there a way to change only the center section of the gauge?
Any example code would be most helpful.
Thanks!
Circular Guage Color
Re: Circular Guage Color
Hello Tech44,
I think you can do something as next code made it in winforms but you should be able to do the same using MonoTouch code.
Can you tell us if previous code works as you want?
I hope will helps.
Thanks,
I think you can do something as next code made it in winforms but you should be able to do the same using MonoTouch code.
Code: Select all
private void InitializeChart()
{
Steema.TeeChart.Styles.CircularGauge gauge = new CircularGauge(tChart1.Chart);
//change FaceBrush
gauge.FaceBrush.Solid = true;
gauge.FaceBrush.Gradient.Visible= true;
gauge.FaceBrush.Gradient.Direction = System.Drawing.Drawing2D.LinearGradientMode.ForwardDiagonal;
gauge.FaceBrush.Gradient.StartColor = Color.BlueViolet;
gauge.FaceBrush.Gradient.MiddleColor = Color.Aqua;
gauge.FaceBrush.Gradient.EndColor = Color.BlueViolet;
//Change
gauge.Frame.OuterBand.Color = Color.GreenYellow;
gauge.Frame.OuterBand.Gradient.Visible = false;
gauge.Frame.MiddleBand.Color = Color.GreenYellow;
gauge.Frame.MiddleBand.Gradient.Visible = false;
gauge.Frame.InnerBand.Color = Color.GreenYellow;
//Change BorderWidth
//Outer
gauge.Frame.FrameElementPercents[2] = 20;
//Middle
gauge.Frame.FrameElementPercents[1] = 75;
//Inner
gauge.Frame.FrameElementPercents[0] = 10;
}
I hope will helps.
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Circular Guage Color
Wonderful! I had to make a few changes for iOS differences but that got me exactly what I needed. Thank you!
Re: Circular Guage Color
Hello Tech44,
I am glad that my solution works for you
Thanks,
I am glad that my solution works for you
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |