Data-Binding Expressions

What we have examined so far is the most common form of data binding that involves list and iterative controls and collections of data. It is important to note that any of the ASP.NET controls support some minimal form of data binding, including text boxes and labels, through the DataBind method. In its simplest form, a binding is a connection between one piece of data and a server control property. This simple form of binding is established through a special expression that gets evaluated when the code in the page calls the DataBind method on the control.

Simple Data Binding

A data-binding expression is any executable code wrapped by <% ... %> and prefixed by the symbol #. Typically, you use data-binding expressions to ...

Get Programming Microsoft® ASP.NET 3.5 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.