Page 1 of 1

Scrollbars appearing unexpectedly

Posted: Wed Nov 28, 2007 1:41 am
by 8739068
I have a case where I am using a TeeChart control on a dialog. When the dialog first displays, it is NOT maximized. When I maximize the dialog, the chart resizes as I expected. But when I restore the size by clicking on the "Restore Down" button at the top right of the dialog, the chart resizes but has both a horizontal scrollbar and a verticle scrollbar. If I resize the dialog just slightly. The scrollbars disappear.

The chart is displaying a simple X-Y data.
The Anchor property is set to anchor on top, left, right, bottom.

I have set several chart properties to non-defaults. Here is a snippet of code that might have an effect on the scrollbars

// X axis
this.Axes.Bottom.Automatic = false;
this.Axes.Bottom.Minimum = sizes[0, 0];
this.Axes.Bottom.Maximum = sizes[0, 1];
this.Axes.Bottom.MinimumOffset = 1;
this.Axes.Bottom.MaximumOffset = 1;
// Y axis
this.Axes.Left.Automatic = false;
this.Axes.Left.Minimum = sizes[1, 0];
this.Axes.Left.Maximum = sizes[1, 1];
this.Axes.Left.MinimumOffset = 1;
this.Axes.Left.MaximumOffset = 1;

Is there a property I should be setting that will prevent the scrollbars from showing?

I do allow the user to pan the chart by using the Chart Controller and with a mouse click and drag move the charting surface around. I want to make sure this feature remains in effect.

Posted: Wed Nov 28, 2007 8:30 am
by narcis
Hi Mike,

I'm not able to reproduce the problem here. Could you please send us a simple example project we can run "as-is" to reproduce the problem here?

You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.

Thanks in advance.

May take some time to reproduce

Posted: Wed Nov 28, 2007 2:14 pm
by 8739068
I am not sure if I can throw together a simple example, quickly. We are on a deadline for a release. I will try to put something together in the next week or so.

I was hoping you can point me to a property I might set that would disable any scrollbars from appearing.

Posted: Wed Nov 28, 2007 2:38 pm
by narcis
Hi Mike,

Sorry but this is the first time I hear this issue with TeeChart and I have no idea on what the problem can be. However, this issue could be common to all components derived from System.Windows.Forms.Control similar to TeeChart like a System.Windows.Forms.Panel.

It would be very helpful if, when you have some time available, you could arrange a simple example project we can run "as-is" to reproduce the problem here.

Thanks in advance.

Not a problem with the chart control

Posted: Fri Nov 30, 2007 6:14 pm
by 8739068
I found the issue. it was not with the TeeChart control, but instead a
FlowLayoutPanel control that contained the TeeChart control. Not sure why the scroll bars would appear after maximizing and then restoring the dialog, but they do.

I turned off the auto scrolling on the FlowLayoutPanel and that fixed my issue.

Posted: Mon Dec 03, 2007 10:57 am
by narcis
Hi Mike,

Thanks for the information. I'm glad to hear you solved the issue.