<script runat="server">
sub Update(sender As Object, e As EventArgs)
if Page.IsValid then
lblText.Text="Page is valid!"
else
lblText.Text="page is not valid!"
end if
end sub
</script>
<html>
<body>
<form runat="server">
Enter US zip code Please:
<asp:TextBox id="txtZipcode" runat="server" />
<asp:Button text="Process" OnClick="Update" runat="server" />
<asp:Label id="lblText" runat="server" />
<br />
<asp:RegularExpressionValidator
ControlToValidate="txtZipcode"
ValidationExpression="\d{5}"
EnableClientScript="false"
ErrorMessage="Zip code should be 5 digit numeric"
runat="server" />
</form>
</body>
</html>