FilteredTextBoxExtender FilterMode InvalidChars in asp.net ajax

Ajax FilteredTextBoxExtender FilterMode InvalidChars
UsingFilterModeInvalidChars.aspx

<%@ Page Language="C#" AutoEventWireup="true" %>
<%@ Import Namespace="System.Drawing" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %>

<!DOCTYPE html>
<script runat="server">
    protected void Page_Load(object sender, EventArgs e)
    { 
        if(!Page.IsPostBack)
        {
            Label1.ForeColor = Color.DeepPink;
            Label1.BackColor = Color.Snow;
            Label1.Font.Name = "Comic Sans MS";
            Label1.Height = 75;
            Label1.Width = 450;
            Label1.Font.Size = FontUnit.XLarge;
            Label1.Font.Italic = true;
            Label2.ForeColor = Color.Salmon;
            Label2.Font.Bold = true;
            Label2.Font.Underline = true;
            Label2.Font.Italic = true;
            Label2.Font.Size = FontUnit.Large;     
        }
    }
    protected void Button1_Click(object sender, EventArgs e)
    {
        Label1.Text = "Hi " + TextBox1.Text +"!";
    }    
</script>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>Ajax FilteredTextBoxExtender FilterMode InvalidChars - How to use</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <h2 style="color:OliveDrab; font-style:italic;">Ajax FilteredTextBoxExtender Example: Using FilterMode InvalidChars</h2>
        <hr width="650" align="left" color="salmon" />
        <asp:ScriptManager 
            ID="ScriptManager1"
            runat="server"
            >
        </asp:ScriptManager>
        <cc1:FilteredTextBoxExtender 
            ID="FilteredTextBoxExtender1"
            runat="server"
            TargetControlID="TextBox1"
            FilterMode="InvalidChars"
            InvalidChars="*~!./;;,\[]{}"
            >
        </cc1:FilteredTextBoxExtender>
        <br />
        <asp:Label 
            ID="Label1"
            runat="server"
            >
        </asp:Label>
        <br />
        <asp:Label 
            ID="Label2" 
            runat="server"
            Text="Your Name"
            >
        </asp:Label>
        <br />
        <asp:TextBox 
            ID="TextBox1"
            runat="server"
            Font-Bold="true"
            Height="35"
            Font-Size="Medium"
            ForeColor="OrangeRed"
            >
        </asp:TextBox>
        <br /><br />
        <asp:Button 
            ID="Button1"
            runat="server"
            ForeColor="Olive"
            OnClick="Button1_Click"
            Text="Submit Your Name"
            Font-Bold="true"
            Height="40"
            />
    </div>
    </form>
</body>
</html>
Related asp.net ajax examples