i have one textbox for password, n i want to set character for password, so which property can be used?

You can set the TextMode property of Textbox to Password...

i have one textbox for password, n i want to set character for password, so which property can be used?

Thank u

To set password character in asp.net you will have to set two properties of text box.
1> TextMode="password"
2> PasswordChar = "*" or any other character like "@".

Password char property is not available in asp.net so pls tell me another one answer.

Just set the textmode property of the textbox to "Password".

if it is an mvc project use

 import the model in the top of the razor view file

 add this line of code to generate the password box
 @Html.PasswordFor(m=>m.Password)  -- This would be in your view


 in your model

 public class LoginView{

    public string Username {get;set;}

    [DataType(DataType.Password)]
    public string Password {get;set;}

 }

You can use Textmode properties just write Textmode="Password"

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.