Groups | Blog | Home
all groups > asp.net building controls > january 2004 >

asp.net building controls : Use "Class" to display CSS data in ASP.NET


Rocky Moore
1/13/2004 5:26:23 AM

[quoted text, click to view]
Dear all

As I know, I can use "Class" attribute in ASP to render the HTML control
with some CSS properties. I want to know that is it the same effect in
ASP.NET? But I found it is not.

Below is my code. Please suggest the correction, if I wrong. If not, how can
i use CSS in ASP.NET

<asp:button class="btn" id="btnLogin" runat="server"
Text="Login"></asp:button

--

Server controls have a CssClass property for that. Simply use
CssClass="btn" instead of class=


--
Rocky Moore
www.HintsAndTips.com

Rocky Moore
1/13/2004 7:44:36 AM
I hope this is not duplicated, I posted a reply but did not see it show up
while others did. So if this is a duplicate, sorry!

Server controls have a CssClass property for that. Simply use
CssClass="btn" instead of class=

--
Rocky Moore
www.HintsAndTips.com

[quoted text, click to view]
Dear all

As I know, I can use "Class" attribute in ASP to render the HTML control
with some CSS properties. I want to know that is it the same effect in
ASP.NET? But I found it is not.

Below is my code. Please suggest the correction, if I wrong. If not, how can
i use CSS in ASP.NET

<asp:button class="btn" id="btnLogin" runat="server"
Text="Login"></asp:button

Grey
1/13/2004 6:32:50 PM
Dear all

As I know, I can use "Class" attribute in ASP to render the HTML control =
with some CSS properties. I want to know that is it the same effect in =
ASP.NET? But I found it is not.=20

Below is my code. Please suggest the correction, if I wrong. If not, how =
can i use CSS in ASP.NET

<asp:button class=3D"btn" id=3D"btnLogin" runat=3D"server" =
AddThis Social Bookmark Button