How to use password mode TextBox in

TextBox TextMode Property Password textbox web server control is a simple text input box. but you can change it's text input mode to password input field. textbox web server control's TextMode property help you to create password input control. set the textbox TextMode property value Password, then textbox will act as a password input textbox. Password input textbox hides user input as it being typed. password input textbox can only be single line textbox. we can get password input textbox text by collecting textbox Text property value.
<%@ Page Language="C#" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">

<script runat="server">


<html xmlns="">
<head runat="server">
    <title>TextBox example: how to use TextMode property Password</title>
    <form id="form1" runat="server">
        <asp:Label ID="Label1" runat="server" Text="Email" AssociatedControlID="TextBox1"></asp:Label>
        <asp:TextBox ID="TextBox1" runat="server" TextMode="SingleLine"></asp:TextBox>
        <br />
        <asp:Label ID="Label2" runat="server" Text="Password" AssociatedControlID="TextBox2"></asp:Label>
        <asp:TextBox ID="TextBox2" runat="server" TextMode="Password"></asp:TextBox>
        <br />
        <asp:Button ID="Button1" runat="server" Text="Login" />

Related example