Original article: http://www.cnblogs.com/china-liuyang/articles/1050162.html
Differences between stylesheettheme and theme
First, create a file named text. Skin and write it in it.
Text. Skin
<Asp: textbox runat = "server" width = "80px"/> // set the textbox width to 80px.
<Asp: button runat = "server" width = "60px"/> // set the width of the button to 60px.
Then introduce the appearance file on the hello. ASPX page. We use stylesheettheme to introduce
<% @ Page Language = "C #" autoeventwireup = "true" codefile = "Hello. aspx. cs" inherits = "hello" stylesheettheme = "text. Skin" %>
<! Doctype HTML public "-// W3C // dtd xhtml 1.0 transitional // en" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<HTML xmlns = "http://www.w3.org/1999/xhtml">
<Head runat = "server">
<Title> test </title>
</Head>
<Body>
<Form ID = "form1" runat = "server">
<Div>
<Asp: textbox id = "txttest" runat = "server" width = "100px"> </ASP: textbox> <! -- Fix the txttest length to 100px -->
<Asp: textbox id = "txttest1" runat = "server"> </ASP: textbox> <! -- Do not set the length for txttest1 -->
<Asp: button id = "btntest" runat = "server" text = "button"/> <! -- Do not set the length for btntest -->
</ASP: dropdownlist>
</Div>
</Form>
</Body>
</Html>
The page effect is as follows: the final width of txttest is 100px; the length of txttest1 is 80px; and the length of btntest is 60px. This indicates that the control is fixed in size on the page, then, use the stylesheettheme attribute to reference the appearance file. it does not change the fixed size of the control.
If the referenced appearance file property is changed to theme, the width of all textbox on the page will be 80 PX; (whether or not there is a fixed size) Similarly, the width of all button controls will be 60 PX;