Hi,
When I remove the errors off the chart by clicking in the error's checkbox legend, some of the points (and is mark) are going outside the chart. It seems that the maximum value of the X axis is declining.
Sorry for my english, my first language is french
Tiyo
Points and Marks outside chart
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Tiyo,
You can try setting TeeChart's ClipPoints property to true:
Another alternative is implementing the following code on TeeChart's AfterDraw event:
If after aplying my suggestions the problem still persists please send us an example we can run "as-is" to reproduce the problem here.
You can post your files at news://www.steema.net/steema.public.attachments newsgroup.
Don't worry, my mother tongue is catalan .
You can try setting TeeChart's ClipPoints property to true:
Code: Select all
tChart1.Aspect.ClipPoints = true;
Code: Select all
private void tChart1_AfterDraw(object sender, Steema.TeeChart.Drawing.Graphics3D g)
{
tChart1.Graphics3D.ClipRectangle(tChart1.Chart.ChartRect);
}
You can post your files at news://www.steema.net/steema.public.attachments newsgroup.
Sorry for my english, my first language is french
Don't worry, my mother tongue is catalan .
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 |
I found something for my case
Hi Narcis,
I finnaly found something working for my code. In my code, the X axis can be switch from "number of days" to "dates". In this case, the code was switching from automatic to manuel axis minimum and maximum. Now I set the min and max manually in the tChart_BeforeDraw event depending wich case we are (days or dates). Now it seems to work properly. I send you this part of the code, maybe It could help another customer one day.
Thanks again and have a nice day !
Tiyo
private void _tChart_BeforeDraw(object sender, Steema.TeeChart.Drawing.Graphics3D g) {
double minimum = _tChart.Axes.Bottom.MinXValue;
double maximum = _tChart.Axes.Bottom.MaxXValue;
if (_radioDays.Checked)
{
_tChart.Axes.Bottom.Minimum = 0;
_tChart.Axes.Bottom.Maximum = maximum + System.Math.Floor(maximum / 6);
}
else
{
_tChart.Axes.Bottom.Minimum = minimum - System.Math.Floor(minimum / 1000);
_tChart.Axes.Bottom.Maximum = maximum + System.Math.Floor(maximum / 1000);
}
}
I finnaly found something working for my code. In my code, the X axis can be switch from "number of days" to "dates". In this case, the code was switching from automatic to manuel axis minimum and maximum. Now I set the min and max manually in the tChart_BeforeDraw event depending wich case we are (days or dates). Now it seems to work properly. I send you this part of the code, maybe It could help another customer one day.
Thanks again and have a nice day !
Tiyo
private void _tChart_BeforeDraw(object sender, Steema.TeeChart.Drawing.Graphics3D g) {
double minimum = _tChart.Axes.Bottom.MinXValue;
double maximum = _tChart.Axes.Bottom.MaxXValue;
if (_radioDays.Checked)
{
_tChart.Axes.Bottom.Minimum = 0;
_tChart.Axes.Bottom.Maximum = maximum + System.Math.Floor(maximum / 6);
}
else
{
_tChart.Axes.Bottom.Minimum = minimum - System.Math.Floor(minimum / 1000);
_tChart.Axes.Bottom.Maximum = maximum + System.Math.Floor(maximum / 1000);
}
}
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
You're welcome Tiyo.
I'm glad to hear you could solve the problem. Thanks for your input to the forums, it may be helpful to other users.
I'm glad to hear you could solve the problem. Thanks for your input to the forums, it may be helpful to other users.
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 |