Summary

Team Fly 

Page 288

property in one WebControl, you know how to deal with it in all WebControls. WebControls also sometimes offer high-level abstractions that have no HTML equivalent; the Calendar control is one example.

HTML controls can be useful, though, if you have to maintain or revise an existing ASP or HTML page. This approach might be simpler than translating the pages into.NET WebControlbased WebForms. HTML server-side controls either contains the runat=''server" attribute or are enclosed with a form element that itself has the runat server attribute, like this HTML password control:

 <form id= "WebForm1" method== "post" runat= "server" > <input type=password> </form> 

Should you want to compel an HTML control to execute server-side like a server control, right-click the control in the design window and choose Run As Server Control. The Button control, for example, defaults to client-side execution.

Summary

This chapter explored the novel features that ASP.NET and ADO.NET bring to the previously formidable job of building data-driven websites. The chapter begins with a survey of the several problems solved by using web pages in concert with server-side controls such as the powerful, flexible DataGrid. You saw how using server-side controls to compose HTML pages for transmission to client browsers solves issues as disparate as security and bandwidth.

This chapter describes how to use various WebForm controls such as DataGrid, DataList, and Repeater. You also saw how to employ templates, deal with postback, and handle validation (both programmatic and control enforced validating). A technique for efficient graphics transmission was discussed. Finally, we covered a couple of reasons why—in spite of the clear superiority of server-side controls—you might want to occasionally revert to using legacy HTML controls instead.

Team Fly 


Visual Basic  .NET Power Tools
Visual Basic .NET Power Tools
ISBN: 0782142427
EAN: 2147483647
Year: 2003
Pages: 178

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net