Documentation for: ASP.NET Ajax Version 1.0

This documentation is for a previous version. For the current released version, see the ASP.NET Ajax documentation on MSDN.








ClientEventExample1 Sample


<%@ Page Language="C#" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 

<script runat="server">


<html xmlns="" >
<head runat="server">
    <title>Client Event Example</title>
    <style type="text/css">
    #OuterPanel { width: 600px; height: 200px; border: 2px solid blue; }
    #NestedPanel { width: 596px; height: 60px; border: 2px solid green; 
                   margin-left:5 px; margin-right:5px; margin-bottom:5px;}
    <form id="form1" runat="server">
        <asp:ScriptManager ID="ScriptManager1" runat="server">
           <asp:ScriptReference Path="ClientEventTest.js" />
        <asp:UpdatePanel ID="OuterPanel" UpdateMode="Conditional" runat="server">
            Postbacks from inside the outer panel and inner panel are
            asynchronous postbacks. PRM = Sys.WebForms.PageRequestManager. APP = Sys.Application.

            <br /><br />
            <asp:Button ID="OPButton1" Text="Outer Panel Button" runat="server" />
            Last updated on
            <%= DateTime.Now.ToString() %>
            <br /><br />

            <asp:UpdatePanel ID="NestedPanel" UpdateMode="Conditional" runat="server">
                <asp:Button ID="NPButton1" Text="Nested Panel 1 Button" runat="server" />
                Last updated on
                <%= DateTime.Now.ToString() %>
                <br />

        <input type="button" onclick="Clear();" value="Clear" />

        <asp:Button ID="FullPostBack" runat="server" Text="Full Postback" />
        <a href="">Test Window Unload</a>
        <br />
        <span id="ClientEvents"></span>