adding a series to the legend reduces the chart size.

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
usc
Newbie
Newbie
Posts: 29
Joined: Thu Mar 09, 2006 12:00 am
Contact:

adding a series to the legend reduces the chart size.

Post by usc » Fri Jul 27, 2007 12:36 pm

When ever a new series is added to the legend, the plot decreases in size.How can I overcome this issue.

1. I want the Legend to be at the top of the chart with a vertical scrollbar and fixed size.

Edu
Advanced
Posts: 206
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia

Post by Edu » Mon Jul 30, 2007 10:01 am

Hi Usc

You can use a CustomPosition to the legend, and fix a top margin for the Chart, you can do something similar to below code:

Code: Select all

            tChart1.Legend.CustomPosition = true;
            tChart1.Legend.Top = 10;
            tChart1.Legend.Left = 30;
            tChart1.Panel.MarginTop = 20;
Best Regards,
Edu

Steema Support Central
http://support.steema.com/

usc
Newbie
Newbie
Posts: 29
Joined: Thu Mar 09, 2006 12:00 am
Contact:

Post by usc » Mon Jul 30, 2007 11:51 am

Hi Edu,

Is there any way by which I can attach a screen shot of the problem that I a facing and send it to you, so that you can appreciate my problem.

Regards,
Uday

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Mon Jul 30, 2007 11:53 am

Hi Uday,

Yes, you can send us files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.

Thanks in advance.
Best Regards,
Narcís Calvet / 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

usc
Newbie
Newbie
Posts: 29
Joined: Thu Mar 09, 2006 12:00 am
Contact:

Post by usc » Mon Jul 30, 2007 12:44 pm

Hi Narcis

Thanks for your reply. I have uploaded [img]Chart_Legend.bmp[/img] file for reference to the problem I am facing.

On the right hand side of the imae, I have a checked list box displaying various groups.On checking of a particlar group, a series is made visible to the chart and it gets added to the legend as well.

When I add a series to the legend, the chart size is reducing.I implemented the solution sent by Edu in the above mail and it repositions the legend and does not reduce the chart size but there is an overlap between the legend and the chart. I thought of adding a vertical scrollbar to the legend as a possible solution but I am not able to do so.Its coming as horizontal.

Kindly suggest me a possible solution to overcome this problem.

Edu
Advanced
Posts: 206
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia

Post by Edu » Tue Jul 31, 2007 11:29 am

Hi usc

A possible solution can be using a LegendScrollBar tool and MaxNumRows property, but this property doesn't work fine.

I've added it (TF02012372) to our defect list to be fixed for future releases.

Please be aware at this forum for new release announcements and what's fixed/implemented on them.
Best Regards,
Edu

Steema Support Central
http://support.steema.com/

usc
Newbie
Newbie
Posts: 29
Joined: Thu Mar 09, 2006 12:00 am
Contact:

Post by usc » Tue Aug 07, 2007 6:13 am

Hi Edu

Is it possible to add the legend to another control. say for example a List view control of system.Windows.Forms.

Regards,
Usc

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Tue Aug 07, 2007 10:14 am

Hi usc,

You can try using a ChartListBox component for that. It inherits from System.Windows.Form.ListBox.
Best Regards,
Narcís Calvet / 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

usc
Newbie
Newbie
Posts: 29
Joined: Thu Mar 09, 2006 12:00 am
Contact:

Post by usc » Wed Aug 08, 2007 10:24 am

Hi Narcis,

With refernce to the image Chart_Legend, I am trying to use the chart listbox control as a legend. Is it possible to add the series values to the chartlistbox at run time.

I have different plot groups on the right side.If I check on one plot group a number of different series are made visible.I just want to add those series at runtime and display in the chart list. similarly when I uncheck the plot group I want corresponding series in the chartlist to be removed.

Can you help me out in achieving this.

Thanks and Regards,
Uday

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Aug 08, 2007 10:35 am

Hi Uday,

Here you can find an example for a client that requested something similar as you.

Regarding adding values to the series, you should do that adding and Editor or a ChartController to your form to be able to access your chart editor.
Best Regards,
Narcís Calvet / 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