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

CSS (StyleSheets)

3 Answers 106 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Pan hal
Top achievements
Rank 1
Pan hal asked on 21 Aug 2009, 04:51 PM

How to create style sheet in Silverlight 3.0.  Is 'CSS calss' concept can be used here.
Provide an example demonstrating how to use stylesheets(CSS).  We are used for CSS and hope this is available in silverlight.

3 Answers, 1 is accepted

Sort by
0
Nikolay
Telerik team
answered on 26 Aug 2009, 07:21 AM
Hello Pan hal,

Thanks for your question. No CSS can be used in Silverlight. You can only use XAML. To use similar concept (as with CSS in HTML) you can place your common resources in the app.xaml file for example and the include them where necessary in the XAML declarations of the controls.

You can also refer to the following tutorial for a better understanding:

http://weblogs.asp.net/scottgu/pages/silverlight-tutorial-part-4-using-style-elements-to-better-encapsulate-look-and-feel.aspx

Kind regards,
Nick
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Pan hal
Top achievements
Rank 1
answered on 04 Sep 2009, 03:56 PM
Thankyou so much. We have 6 different clients and needs to have different backround color for  different clients for same one application. In our  .Net application(infragistics) we had one 'Generic.css'  where all property along with background colors are defined and then imported the  same into other css for different clients.

For example for client 'ABC' created 'ABC.css' and imported generic.css into this ABC.css and override  only background color in ABC.css.

How to implement this concept in silverlight.
0
Dimitrina
Telerik team
answered on 11 Sep 2009, 10:37 AM
Hello Pan hal,

You can apply  a custom theme to any of  the controls. For more information you can follow the link below:
http://www.telerik.com/help/silverlight/radcontrols-for-silverlight-expression-blend-support.html 

Please find attached an example for your reference.

If you have any further question please do not hesitate to ask.

I hope this will help you.


Regards,
Dimitrina
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
General Discussions
Asked by
Pan hal
Top achievements
Rank 1
Answers by
Nikolay
Telerik team
Pan hal
Top achievements
Rank 1
Dimitrina
Telerik team
Share this question
or