Skip to main content
Home Forums Silverlight Programming Programming with .NET - General What is the equivalent of HTML CSS in Silverlight
3 replies. Latest Post by Amanda Wang - MSFT on April 17, 2009.
(0)
a_anandr...
Member
15 points
163 Posts
04-14-2009 3:12 AM |
Hi
I want to define my Styles in one place and use it across all Silverlight Projects. I know we can add the styles in the App.xaml. But is there any way like CSS in HTML. Can I define it in one place and include it to the project to get my Styles Applied.
Thanks
Anandraj.A.
MarkMonster
Contributor
5220 points
1,046 Posts
04-14-2009 3:47 AM |
In Silverlight we have Styles and Templates. Maybe this site can help: http://www.silverlightshow.net/Tips/StylesAndTemplates.aspx
04-14-2009 6:10 AM |
Thanks for the Reply.
I am lokking for a solution in SL 2. I want to have a Styles in a separate file and load that at runtime. So that I can maintain a single file for style across Silverlight Applications.
Amanda W...
All-Star
17241 points
1,466 Posts
04-17-2009 2:05 AM |
Hi Anandraj.A. ,
You can try to place your style in a separate xaml file, then you can use ImplicitStyleManager to apply the style to the control.
About how to use it you can try to refer this link: http://silverlight.net/blogs/jesseliberty/archive/2008/10/31/themes-revisited-the-implicit-style-manager.aspx