Web Parts

Web Parts allow your users to reconfigure sections of your site to meet their own needs and preferences. Many information providers allow the user to pick which content they want displayed and in which column to display it. Web Parts allow you to provide that functionality with drag and drop “parts” of your page.

To learn about Web Parts, create a new web site (call it WebParts) and copy the SitePersonalization web site from the beginning of this chapter. Set the Welcome page as the start page and ensure you can log in with an account you created previously (or, alternatively, set CreateAccount as the start page and create a new account to use).

Radio button list label is red

Figure 13-15. Radio button list label is red

Web Parts Architecture

Web Parts are created and managed on top of personalization using a structural component, called the WebPartManager control, to manage the interaction of Web Parts and UI Controls to create user-managed interface.

Every Web Parts page has a WebPartManager control. This invisible control tracks all the individual web part controls and manages the Web Parts Zones (described below). It also tracks the different display modes of the page and if personalization of your Web Parts page applies to a particular user or all users.

Creating Zones

A page that uses Web Parts is divided into zones : areas of the page that can contain content and controls that derive from the Part class ...

Get Programming ASP.NET, 3rd Edition 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.