Pie Chart Size
-
- Newbie
- Posts: 11
- Joined: Mon Jan 19, 2004 5:00 am
Pie Chart Size
My Pie Chart gets smaller as the data qty increases, ie a pie with 2 values, one of 4 and one 3, this is correct size. Another pie with the same size but has 2 values one, 3000 and one of 6000 and the pie is very small. The chart size in both cases is Width="508px" Height="221px"
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi MikeTheLad,
This is because the legend strings are longer and this takes space from the rest of the chart area. You can solve this by making the legend not visible or forcing the ValueFormat having 3 fix decimal digits:
This is because the legend strings are longer and this takes space from the rest of the chart area. You can solve this by making the legend not visible or forcing the ValueFormat having 3 fix decimal digits:
Code: Select all
pie1.Add(4);
pie1.Add(3);
pie1.ValueFormat = "#,##0.000";
pie2.Add(2000);
pie2.Add(3000);
Best Regards,
Narcís Calvet / 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 |
-
- Newbie
- Posts: 11
- Joined: Mon Jan 19, 2004 5:00 am
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi MikeTheLad,
Yes, you can achieve that using the GetLegendText event adding the symbol to the legend text string.
Yes, you can achieve that using the GetLegendText event adding the symbol to the legend text string.
Best Regards,
Narcís Calvet / 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 |
-
- Newbie
- Posts: 11
- Joined: Mon Jan 19, 2004 5:00 am
Understand what you are saying, I have created the event as per tuturial 5 but when I build the project I get,
the type name 'GetLegendTextEventArgs' does not exist in the type 'Steema.TeeChart.TChart'
when I type Steema.TeeChart.TChart. in the event on the list of available command GetLegendText is not there.
the type name 'GetLegendTextEventArgs' does not exist in the type 'Steema.TeeChart.TChart'
when I type Steema.TeeChart.TChart. in the event on the list of available command GetLegendText is not there.
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi MikeTheLad,
You can automatically create the even at TeeChart's event section in the property window or at run-time like this:
You can automatically create the even at TeeChart's event section in the property window or at run-time like this:
Code: Select all
private void Form1_Load(object sender, EventArgs e)
{
candle1.FillSampleValues();
tChart1.GetLegendText += new Steema.TeeChart.GetLegendTextEventHandler(tChart1_GetLegendText);
}
void tChart1_GetLegendText(object sender, Steema.TeeChart.GetLegendTextEventArgs e)
{
e.Text = "£" + e.Text;
}
Best Regards,
Narcís Calvet / 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 |
-
- Newbie
- Posts: 11
- Joined: Mon Jan 19, 2004 5:00 am
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi MikeTheLad,
Yes, this is possible. You can do that using the chart editor at design-time or at run-time using:
Yes, this is possible. You can do that using the chart editor at design-time or at run-time using:
Code: Select all
tChart1.Legend.Alignment = Steema.TeeChart.LegendAlignments.Bottom;
Best Regards,
Narcís Calvet / 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 |
-
- Newbie
- Posts: 11
- Joined: Mon Jan 19, 2004 5:00 am
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi MikeTheLad,
Ok, then you can use legend's custom position:
Ok, then you can use legend's custom position:
Code: Select all
tChart1.Legend.CustomPosition = true;
tChart1.Legend.Top = tChart1.Height - 50;
tChart1.Legend.Left = tChart1.Width / 2;
tChart1.Panel.MarginBottom = 15;
Best Regards,
Narcís Calvet / 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 |