Next


Skins

• Skins are similar to CSS classes.
• Similar to CSS class, the skin has a name.
• It can be written in the “.skin” file.
• One skin file may contain any no. of skins.

Implementation:
• Create the tag designs with “SkinID” attribute (in the skin file):
<tag runat=”server” property=”value” SkinID=”skin name” />
• Access the Skin with “SkinID” attribute (in the aspx page):
<tag runat=”server” SkinID=”skin name” />

Demo on Themes

Skins

MyTheme.skin
<asp:TextBox runat="server" Font-Name="Century Gothic" Font-Size="20px" BackColor="Black" ForeColor="White" SkinID="BlackAndWhite" />
<asp:TextBox runat="server" Font-Name="Century Gothic" Font-Size="20px" BackColor="Green" ForeColor="Yellow" SkinID="GreenAndYellow" />

Default.aspx
Document  Theme=MyTheme
TextBox1
TextBox2  SkinID=BlackAndWhite
TextBox3  SkinID=GreenAndYellow