<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Default.aspx.cs" Inherits="_Default" %>

<%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
    Namespace="System.Web.UI" TagPrefix="asp" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Kolory (AJAX - częściowa aktualizacja strony)</title>
</head>
<body>
    <form id="form1" runat="server" defaultfocus="TextBox1">
    <div style="text-align: center">
        <asp:ScriptManager ID="ScriptManager1" runat="server">
        </asp:ScriptManager>
        <br />
        <asp:UpdatePanel ID="UpdatePanel1" runat="server">
            <ContentTemplate>
        <asp:Panel ID="Panel1" runat="server" Height="200px" Width="300px" BackColor="Black">
        </asp:Panel>
            </ContentTemplate>
            <Triggers>
                <asp:AsyncPostBackTrigger ControlID="TextBox1" EventName="TextChanged" />
                <asp:AsyncPostBackTrigger ControlID="TextBox2" EventName="TextChanged" />
                <asp:AsyncPostBackTrigger ControlID="TextBox3" EventName="TextChanged" />
            </Triggers>
        </asp:UpdatePanel>
        &nbsp;
        <br />
        <asp:TextBox ID="TextBox1" runat="server" Width="100px" OnTextChanged="TextBox1_TextChanged" AutoPostBack="True" CausesValidation="True">0</asp:TextBox>&nbsp;
        <asp:TextBox ID="TextBox2" runat="server" Width="100px" AutoPostBack="True" OnTextChanged="TextBox1_TextChanged" CausesValidation="True">0</asp:TextBox>&nbsp;
        <asp:TextBox ID="TextBox3" runat="server" Width="100px" AutoPostBack="True" OnTextChanged="TextBox1_TextChanged" CausesValidation="True">0</asp:TextBox><br />
        <asp:RangeValidator ID="RangeValidator1" runat="server" ControlToValidate="TextBox1"
            ErrorMessage="Wartość R spoza dopuszczalnego zakresu" MaximumValue="255" MinimumValue="0" Type="Integer"></asp:RangeValidator><br />
        &nbsp;
        <asp:RangeValidator ID="RangeValidator2" runat="server" ControlToValidate="TextBox2"
            ErrorMessage="Wartość G spoza dopuszczalnego zakresu" MaximumValue="255" MinimumValue="0" Type="Integer"></asp:RangeValidator><br />
        &nbsp;
        <asp:RangeValidator ID="RangeValidator3" runat="server" ControlToValidate="TextBox3"
            ErrorMessage="Wartość B spoza dopuszczalnego zakresu" MaximumValue="255" MinimumValue="0" Type="Integer"></asp:RangeValidator><br />
        <br />
    </div>
    </form>
</body>
</html>
