ajax controls TextBoxWatermarkExtender,ValidatorCalloutExtender and PasswordStrength

Karthikreddy
Posted by Karthikreddy under ASP.NET AJAX category on | Points: 40 | Views : 7306
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<%@ Register assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title>Untitled Page</title>
<style type="text/css">
.Message
{
color:Green;

}
</style>
</head>
<body>
<form id="form1" runat="server">
<br />
<asp:ScriptManager ID="ScriptManager1" runat="server">
</asp:ScriptManager>
<br />
<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
<asp:TextBoxWatermarkExtender ID="TextBox1_TextBoxWatermarkExtender"
runat="server" Enabled="True" TargetControlID="TextBox1"
WatermarkText="User Name">
</asp:TextBoxWatermarkExtender>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server"
ControlToValidate="TextBox1"></asp:RequiredFieldValidator>
<ajaxToolkit:ValidatorCalloutExtender ID="karthik" runat="server" TargetControlID="RequiredFieldValidator1" Width="250"
HighlightCssClass="highlight" WarningIconImageUrl="~/images/1.png" CloseImageUrl="~/images/3.png"></ajaxToolkit:ValidatorCalloutExtender>
<br />
<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>
<asp:PasswordStrength ID="TextBox2_PasswordStrength" runat="server"
Enabled="True" TargetControlID="TextBox2" TextCssClass="Message">
</asp:PasswordStrength>
<asp:TextBoxWatermarkExtender ID="TextBox2_TextBoxWatermarkExtender"
runat="server" Enabled="True" TargetControlID="TextBox2"
WatermarkText="Password">
</asp:TextBoxWatermarkExtender>
<br />
<asp:Button ID="Button1" runat="server" Text="Button" />

</form>
</body>
</html>

Comments or Responses

Login to post response