<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ControlsExample4.aspx.cs" Inherits="FormControls.ControlsExample4" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title>WFC Example: Client-Side Intercept</title>
<script lang="javascript" type="text/javascript">
function Display() {
document.getElementById("lblMessage").innerHTML = "Client received: " + document.getElementById("txtName").value;
}
</script>
</head>
<body>
<h3>Method 2: Intercepting a Web Form (ASPX) Control on the
client-side <br /><br />
This method demonstrates the ability to
add HTML Form Control attributes to a Web Form Control.<br />
The asp:TextBox Web Form Control doesn't have the OnKeyPress attribute, but it gets added <br />
on the
server-side.</h3>
<form id="form1" runat="server">
<asp:Label ID="lblMessage" runat="server" Font-Bold="True" ForeColor="#CC0000"></asp:Label>
<br />
<asp:TextBox ID="txtName" runat="server"></asp:TextBox>
<asp:Button ID="btnSubmit" runat="server" Text="Submit" OnClick="btnSubmit_Click" />
</form>
</body>
</html>