www.gibmonks.com

Main Page

  Previous Section Next Section

Chapter 5. ASP.NET Server Controls

Controls provide the familiar elements of a graphical user interface (GUI): buttons, drop-down boxes, checkboxes, etc. Server controls are controls that enable server-side processing. They provide a range of functionality, from simple data entry to complex data validation.

ASP.NET ships with a suite of ready-to-run server controls you can use to develop powerful Web Forms pages. A key component of the ASP.NET development model, these server controls abstract significant amounts of programming logic into simple-to-use tags. Server controls make it easy to separate programmatic logic from UI elements using code-behind, because you typically instantiate the controls using a tag-based syntax while keeping your UI-related logic in a separate code-behind file. In practical terms, this means that programmers can hand over a .aspx page to UI designers without having to worry about their programming logic getting completely ruined in the process.

In ASP.NET, it's easy for developers to create their own controls from scratch or to build on the functionality of existing controls by creating user controls that combine HTML, server controls, and other page elements, or by creating their own custom server controls. We'll discuss both techniques in Chapter 6.

ASP.NET Server Controls are classified as either HTML controls or web controls. This chapter summarizes the standard controls and the various methods for creating and modifying them.

      Previous Section Next Section