I installed the new Decemeber CTP Atlas VSI today and so far I am pretty impressed. I have only done a quick sample, but it is very impressive and easy to use. In a previous post, I talked about the UpdatePanel, but I did not realize at the time how easy they have made it to use.

What the UpdatePanel does is allow you to put any kind of regular server side control (i.e.: textbox, buttons, gridviews, you name it) and it will automatically intercept those controls postback events and convert them to callbacks. This means that you do not need to have any specific knowledge of AJAX or of how callbacks work in order to dynamically update a portion of the page.

The way it works is simple. First start by turning on partial rendering by passing a value of true to the EnablePartialRendering attribute like in the example below.

<atlas:ScriptManager ID="ScriptManager1" EnablePartialRendering="true" 
runat="server" />

Once you have registered it start by creating a new UpdatePanel. In this panel, you specify a ContentTempalate. It is in there that you can put any server side controls that you want including registering events as normal (i.e.: button click, etc.). There is also a triggers element that allows you some more customization of when to intercept postback events.

Here is an example of it in use. In this case my button click event fires the event handling method defined in the code behind that simply appends some text to the string in the textbox and writes it out to a label. All of this happens without a postback occuring.

<atlas:UpdatePanel ID="UpdatePanel1" Mode="Always" runat="server">
  <ContentTemplate>
    <asp:TextBox ID="TextBox1" runat="server" />
    <asp:Button ID="Button1" runat="server" Text="Submit" 
OnClick="Button1_Click" />
    <asp:Label ID="Label1" runat="server" />
  </ContentTemplate>
</atlas:UpdatePanel>

That is all it takes to take advantage of this in Atlas. If you are interested in downloading the Atlas CTP, you can get it at the link below.

Atlas December CTP

Read the complete post at http://www.dotnettipoftheday.com/blog.aspx?id=228