Home / AJAX

DataView Control and Ajax Templates

RSS
Modified on 2009/11/16 05:51 by Dan Wahlin Categorized as Uncategorized
JavaScript Object Notation(JSON) provides an excellent way to exchange data between Ajax-enabled applications and services. Although JSON data is supported by all of today's mainstream browsers, binding JSON objects to client-side controls can be a tedious and time consuming process especially when large amounts of data are exchanged. The ASP.NET Ajax Library provides a simple yet flexible way to bind JSON data to custom templates resulting in reduced code and simplified maintenance. The object that makes this possible is the DataView component located in the Sys.UI namespace.

This set of tutorials will demonstrate how the DataView component can be used to work with JSON data embedded within a page as well as how the DataView can be used to fetch JSON data from remote services and bind it to client-side templates. Topics covered include:

  • Using the DataView to load and bind JSON data to templates
  • Using the DataView to fetch data from remote services and bind it to templates
  • Creating a DataView component in code
  • Defining a DataView component declaratively using attributes