We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Alternate scrollbar styles possible?

Is it possible to get the GridControl to draw scrollbars differently than the system default style?

I'd like to get the scrollbars to have a "flat" appearance for my project. Is this doable?


2 Replies

MS Maxim Software Systems November 10, 2008 12:14 PM UTC

So, I'm guessing this isn't possible?



NR Nirmal Raja Syncfusion Team November 24, 2008 08:57 PM UTC

Hi Don,

Thank you for your interest in Syncfusion controls.

The scroll bar can be made appear to be in different style by making the scrollbar mode to be flat.
A scrollbar has to be derived independent of the grid control and then it has to be added with Grid.

Please refer the sample code below:

FlatHScrollBar hFlatScrollBar1 = hFlatScrollBar1 = new FlatHScrollBar();

this.hFlatScrollBar1.Appearance = FlatScrollBarStyle.Encarta;

FlatHScrollBar vFlatScrollBar1 = new Syncfusion.Windows.Forms.FlatVScrollBar();

this.vFlatScrollBar1.Appearance = Syncfusion.Windows.Forms.FlatScrollBarStyle.Encarta;

gridControl1.HScrollBehavior = GridScrollbarMode.Shared;

gridControl1.VScrollBehavior = GridScrollbarMode.Shared;

gridControl1.UseSharedScrollBars = true;

gridControl1.VScrollBar.InnerScrollBar = vFlatScrollBar1;

gridControl1.HScrollBar.InnerScrollBar = hFlatScrollBar1;


Let me know if you have any queries.

Regards,
Nirmal


Loader.
Live Chat Icon For mobile
Up arrow icon