Introduce DataBase,Asp.net,JavaScript,Xml,Html,Css,Sql,Php,ASP.NET Controls,AJAX,Tools,HTML,CSS,JavaScript,Open Source Project,WPF,.Net Framework,Linq
Top Recommended Hosting

Asp.net Server Controls

by the3factory 4/1/2008 8:32:00 AM

Server controls are components used in ASP.NET pages to define the user interface of a Web application. Server controls are the essential element of the Web Forms programming model. They form the basis of a modern, component-based, intuitive forms package that simplifies the development of Web user interfaces, similar to the way that the Microsoft Visual Basic forms package simplified Windows programming. At a high level, server controls provide abstractions of an underlying Web application and presentation technology. For example, the Web controls that ship as part of ASP.NET are abstractions of the HTML and HTTP technologies used in the creation of browser-based applications. These controls are described as abstractions because they do not directly represent HTML elements; instead, they offer a more abstract object model for creating those elements.

The Web Forms programming model greatly simplifies application development for page developers and designers and is characterized by the server control features and capabilities that follow.

  • Server controls create an intuitive and simpler programming model for the page developer by hiding the inconsistencies and complexities of the underlying technology. For example, the Button Web control maps directly to the <input type="submit"> HTML tag and hides the inconsistencies of the type attribute of the <input> tag. The TextBox Web control is slightly more sophisticated and maps to one of the multiple text entry tags provided by HTML: <input type="text">, <input type="password">, and <textarea>. At the other end of the spectrum, controls such as Calendar and DataGrid provide new functionality that is not inherently available in HTML, such as date selection and data binding.

  • They hide the differences between various browsers and viewing devices, as well as the various browser versions that a Web application might need to target. The ability of server controls to render content as appropriate to the target browser enables the page developer to write a single application that can target multiple viewing platforms at run time. Server controls contain the logic to provide the best possible experience by examining the capabilities of the requesting browser or device.

  • They function as true components, providing the same benefits that you might expect from working with components in other types of applications. Server controls provide a rich server-side programming model. They expose their functionality through properties and methods. They also provide an event-based programming model, which allows page developers to implement application logic in response to user interaction. The object model exposed by server controls is strongly typed like that of DHTML, which is loosely typed. Not only does being strongly typed lead to better server control performance, it also reduces programming errors.

  • They manage their state across postbacks and round-trips. A scalable Web application is statelessn other words, the application doesn't maintain data and state on the server corresponding to each user accessing the application. Server controls use a feature of the ASP.NET page framework known as view state to manage their state across individual Web requests. This feature allows controls to provide a stateful programming model that creates the illusion of continuity while preserving the scalability of a stateless application.

  • They contain logic to handle postback data associated with a Web request and to enable the page developer to process user input and handle user actions in their server-side code. The page developer is freed from understanding the details of postback and can instead focus on the object model of the controls other words, the controls' properties and events.

  • They provide a compelling data-binding model. Most Web applications are dynamic and feature content based on a variety of data sources. Data-bound server controls hose server controls associated with a data source reatly simplify the creation of dynamic pages. ASP.NET features an efficient data-binding model that provides the page developer with complete control over the data-binding process and over data access. The data-binding model features a simple and generic data source model that provides the page developer with a wide choice of objects that can be used as data sources.

  • They provide page developers with multiple mechanisms to customize their rendering. Server controls can provide style properties as a means to customize their formatting. They can also provide template properties for customization of their content and layout. Server controls use both these mechanisms to provide a lookless user interface, which is an interface that does not provide a single preestablished look but instead can blend seamlessly into the rest of the application's user interface.

  • They are configurable on a machine level (via the machine.config file) or on a Web application level (via the web.config file). Server controls can support configurable defaults for their properties, which enables page developers to control or change their behavior uniformly across pages without having to change or recompile the application itself.

  • They provide a rapid application development (RAD) user experience in a visual design-time environment such as Microsoft Visual Studio .NET. This enables page developers and designers to visually compose their pages and customize the appearance of the server controls in a WYSIWYG fashion.

 

 

Related posts

Sign up for PayPal and start accepting credit card payments instantly.


Powered by BlogEngine.NET 1.2.0.0