Global override for ScrollBar style on RadControls

2 posts, 0 answers
  1. Ammaar
    Ammaar avatar
    12 posts
    Member since:
    Dec 2010

    Posted 22 Jan 2013 Link to this post

    I have an application where multiple RadGridViews are being used as well as a RadTreeView. I would like to override the ScrollBar style for all RadControls in the application so that it uses the default Windows ScrollBar style instead of the RadControls own "shiny" version as it creates an inconsistent UI when other normal WPF ScrollViewers are used in the application. Here's an example: (the top is the default Windows 8 ScrollBar, bottom is a RadGridView ScrollBar).

    I've tried adding the following in the application's ResourceDictionary, but it didn't work:

        <Style TargetType="ScrollBar" BasedOn="{StaticResource {x:Type ScrollBar}}"/>
  2. Dimo Mitev
    Dimo Mitev avatar
    20 posts

    Posted 25 Jan 2013 Link to this post

    Hi Ammaar,

     You may reset the style for the ScrollBars through adding an implicit targeted at the ScrollBar as shown below:

    <Style TargetType="{x:Type ScrollBar}"/> 

     I suggest that you use the Telerik StyleManager, however it does not support this scenario.
     You may globally reset the styles for both scrollbars only with NoXAML binaries and pure implicit styles.
     I'm attaching you sample project, which demonstrates how to achieve this result.
     If you want to read more about this you may check our online documentation for further reference following this link:

    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top