ATLAS December CTP Changes

The Atlas CTP is out with some very interesting and positive changes. To get an overall picture of the new changes read Nikhil Kolthari’s latest blog posts Quick Tour of December Atlas CTP and Atlas Script Manager Control. The atlas server controls like

are now gone. This in my opinion is a good thing. The use of these controls seemed awkward and really took away from the momentum that was started with the ASP.NET server site controls. The introduction of the new UpdatePanel control with the ability to drag ASP.NET server controls onto it is a much cleaner approach. This new atlas control along with the new ScriptManager control allow you to perform partial rendering on you aspx page (the thing you wanted from Atlas all along) with the ease of developing using ASP.NET server controls. So how does this actually work. What I did to find out is create a simple MasterPage (see sample code below) and placed my main layout and ScriptManager control in it and created a simple WebForm page that utilized the main layout of the MasterPage. In this WebForm page I added a button to cause a postback and an UpdatePanel control that contained a GridView control. To understand how the data was moving from the client to the server I used the Web Development Helper Tool that Nikhil create to log the HTML traffic as I performed the partial postback. The findings were very interesting. The postback calls the Default.aspx page (the WebForm page I created) sending up my ViewState and the button. On the backend, the page itself goes through all of the normal cycles and returns a very interesting response via the Atlas XMLHTTP request/response mechanism. It returns the UpdatePanel content inside of an xml structure (and not in JASON format) with a root tag of . This type of response is akin to something you might have see a few years back when using XML data islands. As you can see by the Content-Length entry in the response header we are returning quite a bit of data but in this case the GridView controls data is quite large (100 rows). The content return however would be far less than the total page size in cases where you had a lot more content outside of the UpdatePanel. For those of you who have worked with ASP.NET 2.0 you can’t help but think how this seems similar in concept to Implementing Client Callbacks Without Postbacks in ASP.NET Web Pages but without all of the setup hassle. Keep it coming Atlas team!   

The Simple Page Before PostBack

Atlas Partial Page 1

The Simple Page After PostBack

Atlas Partial Page 2

HTML Logs of PostBack

Request

Atlas Partial Page Request

Response

Atlas Partial Page Response

Response Content Expanded

<delta><rendering><head><title

>

Untitled Page

title><style type

=”text/css”>

.atlas__delta { font-family:Lucida Console;

}

 style

>head><form name=”aspnetForm” method=”post” action=”Default.aspx” id=”aspnetForm”>

<div

>

<input type=”hidden” name=”__VIEWSTATE” id=”__VIEWSTATE” value=”o+5MrTJqwv14QrS9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M1Vk90ZY1b9UW7sFsKLdkaWLUxkPxAtASTYgTA3ydGT1BdZ70a7EwYZcnQTrGInPH9oDh9IERzo30xHVIe9m2iqEsHiW7OSv/BIrwtjOBf9qsvHJn2LWPHGkvns7FJMlk2BACwkoeQ1TflobB3q9ccPRZ8UQ8WY=”

/>

div

>

<span id=”ctl00_ContentPlaceHolder1_NewRegion”><

![CDATA[

=”ctl00_ContentPlaceHolder1_Label1″>This is the current time: 10:10:05 AMspan><br />

<br

/>

<div

>

<table cellspacing=”0″ rules=”all” border=”1″ id=”ctl00_ContentPlaceHolder1_GridView1″ style

=”border-collapse:collapse;”>

<tr

>

<th scope=”col”>AddressID

th><th scope=”col”>AddressLine1th><th scope=”col”>AddressLine2th><th scope=”col”>Cityth><th scope=”col”>StateProvinceIDth><th scope=”col”>PostalCodeth><th scope=”col”>rowguidth><th scope=”col”>ModifiedDateth>

tr><tr>

<td>756

td><td>855 East Main Avenuetd><td> td><td>Zeelandtd><td>35td><td>49464td><td>7cc420b7-b43c-4e40-98ed-6c10cec91c54td><td>8/1/2001 12:00:00 AMtd>

tr><tr>

<td>654

td><td>308-3250 Casting Roadtd><td> td><td>Yorktd><td>14td><td>Y024 1GFtd><td>9d67c322-8698-440a-8f3e-5e1e30edbd0dtd><td>8/1/2003 12:00:00 AMtd>

tr><tr>

….. additional rows removed for clearity

tr>

table>

div

>

 

]]>

span>

 <div

>

<input type=”hidden” name=”__VIEWSTATEENCRYPTED” id=”__VIEWSTATEENCRYPTED” value=””

/>

<input type=”hidden” name=”__EVENTVALIDATION” id=”__EVENTVALIDATION” value=”xdbeL1s/63pwUXIWkXIQNCCOsKvlI/mi5WjlFt51TBM=”

/>

div

>form>rendering><deltaPanels>ctl00_ContentPlaceHolder1_NewRegiondeltaPanels><xmlScript><page xmlns:script=”http://schemas.microsoft.com/xml-script/2005″>

<components

/>

page

>xmlScript>delta>

Sample Code

Sample Partial Postback Application

 

 

Leave a Reply

Your email address will not be published. Required fields are marked *