Create Rich Web Apps with AJAX: Listing 1: XML, AJAX-Enable Apps

The UpdatePanel control available in the ASP.NET AJAX Extensions provides a simple and effective way to AJAX-enable applications. It requires only a bit of code, and, as long as you're willing to accept some performance and related drawbacks, it might be all many developers will ever need.

<asp:UpdatePanel ID="upHighlightedProduct" 
   runat="server" 
UpdateMode="Conditional">
   <ContentTemplate>
      <table>
      <tr>
      <td align="left" valign="middle">
      <asp:AdRotator EnableViewState="false"  
      ID="arHighlightedProduct" runat="server" 
      AdvertisementFile="Ads.xml"
      Width="100" Height="75" BorderWidth="0" 
      OnAdCreated=
         "arHighlightedProduct_AdCreated" />
      <asp:Timer ID="timerHighlightedProduct" 
      runat="server" Interval="5000" />
      </td>
      <td align="left" valign="middle">
      <asp:HyperLink ID=
         "hlAdBanner" runat="server" 
      CssClass="adBannerText" />
      </td>
      </tr>
      </table>
   </ContentTemplate>
</asp:UpdatePanel>
comments powered by Disqus
Upcoming Events

.NET Insight

Sign up for our newsletter.

I agree to this site's Privacy Policy.