How can I find out the last visible x-value (position) when I'm zooming in. In other words, I need to know the last shown x-value (independent of any series) of the zoom window and I need to know it in the
tChart_BeforeDrawSeries-method?
Many thanks in advance!
Position in zoom window
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi dotnetjunkee,
You can do what I suggested in your other thread. Why do you need that to be done in the BeforeDrawSeries event?
You can do what I suggested in your other thread. Why do you need that to be done in the BeforeDrawSeries event?
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: 20
- Joined: Fri Dec 05, 2003 5:00 am
unfortunately I cannot do what you suggested because I don't want to know the most right x-value of the series. I want to know the most right x-value that is shown on the canvas.
And I need to do this in the tChart_BeforeDrawSeries-method because I'm working with annotations which need to be sticked to a vertical separator line.
To become a bit more concrete:
Lets say my chart is split into three parts, each part separated from its neighbor part with a separator line. There is an annotation on the left hand-side of a separator line and the last annotation is left hand-side of the right canvas border. When I zoom in, I need to find out if the last annotation should be shown, i. e. if I zoom into the right part of the chart.
That's why I couldn't find a way to use your solution.
Another question: I posted a question on a custom color pallete yesterday. The replay was that there is an example among the delivered demo programs. I've searched for this example but I couldn't find it. So can you post the code please.
Many thanks!
And I need to do this in the tChart_BeforeDrawSeries-method because I'm working with annotations which need to be sticked to a vertical separator line.
To become a bit more concrete:
Lets say my chart is split into three parts, each part separated from its neighbor part with a separator line. There is an annotation on the left hand-side of a separator line and the last annotation is left hand-side of the right canvas border. When I zoom in, I need to find out if the last annotation should be shown, i. e. if I zoom into the right part of the chart.
That's why I couldn't find a way to use your solution.
Another question: I posted a question on a custom color pallete yesterday. The replay was that there is an example among the delivered demo programs. I've searched for this example but I couldn't find it. So can you post the code please.
Many thanks!
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi dotnetjunkee,
Then I'd suggest you to implement that feature in TeeChart's AfterDraw event. If it doesn't work properly you may be interested in posting an example that we can run "as-is" to reproduce the problem here at [url]news://www.steema.net/steema.public.attachments[/url] newsgroup.
The code below already shows you the last value drawn on TeeChart's canvas, not the last value of the series.unfortunately I cannot do what you suggested because I don't want to know the most right x-value of the series. I want to know the most right x-value that is shown on the canvas.
Code: Select all
tChart1.Header.Text="Maximum X Visible Value: " + tChart1.Axes.Bottom.Maximum.ToString();
And I need to do this in the tChart_BeforeDrawSeries-method because I'm working with annotations which need to be sticked to a vertical separator line.
To become a bit more concrete:
Lets say my chart is split into three parts, each part separated from its neighbor part with a separator line. There is an annotation on the left hand-side of a separator line and the last annotation is left hand-side of the right canvas border. When I zoom in, I need to find out if the last annotation should be shown, i. e. if I zoom into the right part of the chart.
That's why I couldn't find a way to use your solution.
Then I'd suggest you to implement that feature in TeeChart's AfterDraw event. If it doesn't work properly you may be interested in posting an example that we can run "as-is" to reproduce the problem here at [url]news://www.steema.net/steema.public.attachments[/url] newsgroup.
You'll find that demo and its sources at TeeChart's example folder. However, the code is too large to be posted in a forums message. Do you mind if I send it to the e-mail address we have for your forums username?Another question: I posted a question on a custom color pallete yesterday. The replay was that there is an example among the delivered demo programs. I've searched for this example but I couldn't find it. So can you post the code please.
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: 20
- Joined: Fri Dec 05, 2003 5:00 am
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi dotnetjunkee,
Ok, I've just send it. Hope you received it.
Ok, I've just send it. Hope you received it.
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 |