Hi
I am creating an area chart in an ios application with multiple area series.
I have set SeriesArea.Transparency = 40;
Due to this all area series appear in the same blue color:
If i do not set the Transparency then it shows like :
So in the screenshot above the two areas are overlapping each other.
Please let me know how to show both areas with some transparency and different colors.
Thanks
Multiple area chart with different colors for each area
Re: Multiple area chart with different colors for each area
Hello,
I cannot reproduce the problem here using the following code, could you please be so kind to check if it works for you?
In the case the problem persist, please post the code you're using in order to test it here and fix if necessary.
Thanks1
I cannot reproduce the problem here using the following code, could you please be so kind to check if it works for you?
Code: Select all
_controller.chart.Series.Add(new Steema.TeeChart.Styles.Area());
_controller.chart.Series.Add(new Steema.TeeChart.Styles.Area());
_controller.chart.Series.Add(new Steema.TeeChart.Styles.Area());
_controller.chart.Series[0].FillSampleValues(5);
_controller.chart.Series[1].FillSampleValues(5);
_controller.chart.Series[2].FillSampleValues(5);
Steema.TeeChart.Styles.Area area1 = _controller.chart.Series[0] as Steema.TeeChart.Styles.Area;
Steema.TeeChart.Styles.Area area2 = _controller.chart.Series[1] as Steema.TeeChart.Styles.Area;
Steema.TeeChart.Styles.Area area3 = _controller.chart.Series[2] as Steema.TeeChart.Styles.Area;
area1.Transparency = 40;
area2.Transparency = 40;
area3.Transparency = 40;
Thanks1
Pep Jorge
http://support.steema.com
http://support.steema.com
Re: Multiple area chart with different colors for each area
Hello Pep
Following is my source code:
Thanks
Following is my source code:
Code: Select all
Steema.TeeChart.Drawing.ChartFont font = new Steema.TeeChart.Drawing.ChartFont();
font.Size = 5;
int SeriesCount = 2;
for (int i=1; i <= SeriesCount; i++)
{
Steema.TeeChart.Styles.Area SeriesArea = new Steema.TeeChart.Styles.Area(chart.Chart);
SeriesArea.Title = "Series" + i;
SeriesArea.Marks.Font = font;
SeriesArea.Transparency = 40;
SeriesArea.Marks.Visible = true;
SeriesArea.Marks.Style = Steema.TeeChart.Styles.MarksStyles.Value;
SeriesArea.Marks.Transparent = true;
}
for (int i=0; i < 10; i++)
{
for (int j=0; j < SeriesCount-1; j++)
{
chart.Chart.Series [j].Add(
Convert.ToDouble(i + j),
Convert.ToString(i + j) + "s"
);
}
}
- Attachments
-
- Screen shot 2012-09-24 at 10.26.58 AM.png (39.09 KiB) Viewed 8916 times
Re: Multiple area chart with different colors for each area
Hello incadea,
Your code helped us to detect your problem. Basically it is produced if you try to change values of transparency property before add points in series. I have added this issue in bug list report with number[TF02016355]. We will try to fix it to upcoming versions of TeeChartFor.Net. On the other hand, at the moment, to solve the problem you must change the values of transparency property after add points of series. You can do something as next code:
I hope will helps.
Thanks,
Your code helped us to detect your problem. Basically it is produced if you try to change values of transparency property before add points in series. I have added this issue in bug list report with number[TF02016355]. We will try to fix it to upcoming versions of TeeChartFor.Net. On the other hand, at the moment, to solve the problem you must change the values of transparency property after add points of series. You can do something as next code:
Code: Select all
Steema.TeeChart.Drawing.ChartFont font = new Steema.TeeChart.Drawing.ChartFont();
font.Size = 5;
int SeriesCount = 2;
for (int i=1; i <= SeriesCount; i )
{
Steema.TeeChart.Styles.Area SeriesArea = new Steema.TeeChart.Styles.Area(chart.Chart);
SeriesArea.Title = "Series" i;
SeriesArea.Marks.Font = font;
//SeriesArea.Transparency = 40;
SeriesArea.Marks.Visible = true;
SeriesArea.Marks.Style = Steema.TeeChart.Styles.MarksStyles.Value;
SeriesArea.Marks.Transparent = true;
}
for (int i=0; i < 10; i )
{
for (int j=0; j < SeriesCount-1; j )
{
chart.Chart.Series [j].Add(
Convert.ToDouble(i j),
Convert.ToString(i j) "s"
);
(chart.Chart.Series[j] as Steema.TeeChart.Styles.Area).Transparency = 40; //solve the problem.
}
}
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: Multiple area chart with different colors for each area
Thanks Sandra. My problem is solved.