how to produce rounded textbox

Posted by Siva524 under C# on 5/7/2012 | Points: 10 | Views : 2274 | Status : [Member] | Replies : 3
how to produce rounded textbox in c#.net?




Responses

Posted by: Sabarimahesh on: 5/7/2012 [Member] Bronze | Points: 25

Up
0
Down
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default6.aspx.cs" Inherits="Default6" %>


<!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">
<style type="text/css">
input
{
border:2px solid #a1a1a1;
padding:10px 40px;
width:300px;
border-radius:25px;
-moz-border-radius:25px; /* Firefox 3.6 and earlier */
}
</style>

<title>Untitled Page</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:TextBox ID="txtUserName" runat="server"></asp:TextBox>
</div>
</form>
</body>
</html>


Life is a Race
Thanks & Regards
By
Sabari Mahesh P M

Siva524, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sabarimahesh on: 5/7/2012 [Member] Bronze | Points: 25

Up
0
Down
http://go4answers.webhost4life.com/Example/rounded-text-box-textboxbase-font-68888.aspx

Life is a Race
Thanks & Regards
By
Sabari Mahesh P M

Siva524, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Gaur1982 on: 5/7/2012 [Member] Starter | Points: 25

Up
0
Down
HTML Code for rounded corner textbox

<div class="loginboxdiv">
<input class="loginbox" name="username" type="text" />
</div>

The container "div" contains the background image of rounded corners and inside of that the real textbox resides.
CSS Code for rounded corner textbox:

.loginboxdiv
{
margin:0;
height:21px;
width:146px;
background:url(login_bg.gif) no-repeat bottom;
}

.loginbox
{
background:none;
border:none;
width:134px;
height:15px;
margin:0;
padding: 2px 7px 0px 7px;
font-family:Verdana, Arial, Helvetica, sans-serif;
font-size:11px;
}

Gaurav Agrawal
http://www.planetofcoders.com/

Siva524, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response