ClickAxis in WPF

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
antoine
Newbie
Newbie
Posts: 15
Joined: Fri Jun 17, 2011 12:00 am

ClickAxis in WPF

Post by antoine » Wed Aug 03, 2011 12:33 pm

Hi,

Is it possible to use the ClickAxis event on a chart (Line and CircularGauge) in WPF?
If yes, can you provide me an exemple?

Thanks,
Antoine.

antoine
Newbie
Newbie
Posts: 15
Joined: Fri Jun 17, 2011 12:00 am

Re: ClickAxis in WPF

Post by antoine » Wed Aug 03, 2011 1:18 pm

I've managed to do it with the Line using this:

Code: Select all

this.tc_Chart.ClickAxis +=new MouseEventHandler(tc_Chart_ClickAxis);

//...

private void tc_Chart_ClickAxis(object sender, MouseEventArgs e)
        {
            Console.WriteLine(e.ToString());
        }
but it does not work with the CircularGauge.

Sandra
Site Admin
Site Admin
Posts: 3132
Joined: Fri Nov 07, 2008 12:00 am

Re: ClickAxis in WPF

Post by Sandra » Thu Aug 04, 2011 9:51 am

Hello Antonie,

I am afraid that it is not possible use ClickAxies in CircularGauge, so Axis of CircularGauge is not visible, therefore no accessible and do ClicAxis Event, loses meaning when you use CircularGauge.

Thanks,
Best Regards,
Sandra Pazos / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

antoine
Newbie
Newbie
Posts: 15
Joined: Fri Jun 17, 2011 12:00 am

Re: ClickAxis in WPF

Post by antoine » Thu Aug 04, 2011 1:31 pm

Ok. To by-pass this limitation I have tried to used the ClickSeries of the TChart component and the Click of the CircularGauge without any success.

Code: Select all

        public void InitTeeChart()
        {
            CircularGauge gauge = new CircularGauge();

            gauge.Click +=new MouseEventHandler(gauge_Click);

            tc_Chart.ClickSeries+=new TChart.SeriesEventHandler(tc_Chart_ClickSeries);

            this.tc_Chart.Series.Clear();
            this.tc_Chart.Series.Add(gauge);

        }

        private void tc_Chart_ClickSeries(Object sender, Series s, Int32 valueIndex, MouseEventArgs e)
        {
            Console.WriteLine("tc_Chart_ClickSeries: " +e.ToString());
        }

        private void gauge_Click(object sender, MouseEventArgs e)
        {
            Console.WriteLine("gauge_Click: " + e.ToString());
        }
Which type of Event should I use to achieve my goal?

Thanks.

Sandra
Site Admin
Site Admin
Posts: 3132
Joined: Fri Nov 07, 2008 12:00 am

Re: ClickAxis in WPF

Post by Sandra » Fri Aug 05, 2011 12:00 pm

Hello antoine,

You are right. I have added your request in bug list report with number [TF02015685]. We will try to fix it in next maintenance releases of TeeChart.Net.

Thanks,
Best Regards,
Sandra Pazos / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply