This is a migrated thread and some comments may be shown as answers.

Sstandard Control Style Not Set

3 Answers 57 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 19 Jun 2012, 01:48 PM
Hi,
Using runtime set style only set telerik control not set wpf standard control.

3 Answers, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 19 Jun 2012, 02:07 PM
Hello,

 I would recommend you to check this documentation article on how to style standard controls.

Greetings,
Didie
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
John
Top achievements
Rank 1
answered on 19 Jun 2012, 04:27 PM
Hi, Using this code error (Error 1 'Telerik.Windows.Controls.StyleManager' does not contain a definition for 'SetBasedOn' C:\Users\John\Documents\Visual Studio 2010\Projects\RadControlsWpfApp3\RadControlsWpfApp3\MainWindow.xaml.cs 33 26 RadControlsWpfApp3
)
0
Accepted
Dimitrina
Telerik team
answered on 20 Jun 2012, 03:04 PM
Hi,

 Indeed you are right - the suggested solution works for Silverlight only.

In order to apply the application Theme for MS Button in WPF you should do the following:

public MainWindow()
{
StyleManager.ApplicationTheme = new Expression_DarkTheme();
InitializeComponent();
}

<Window.Resources>
        <telerik:Expression_DarkTheme x:Key="Theme" />
        <Style TargetType="Button">
               <Setter Property="telerik:StyleManager.Theme" Value="{StaticResource Theme}"/>
        </Style>
</Window.Resources>

Please find attached sample project for a reference.

Thank you for the feedback. I am glad to tell you that I have updated your telerik points. I will update the content in the help article as well.


All the best,
Didie
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
General Discussions
Asked by
John
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
John
Top achievements
Rank 1
Share this question
or