I created a style in XAML, How Can I return this style in style selector (code)?
I created style in XAML and I want to only return the style which is declared in XAML.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You need to access the XAML resource where you stored the style. Generally they way to do this is store it in a seperate resources file. Then you need to access the URI of that XAML file as a ResourceDictionary object. Here is an example where I use a converter to decide which style an element will get.