110 likes | 324 Views
AJAX ASP.NET. MIS 424 Professor Sandvig. Today. ASP.NET AJAX Controls: built-in properties ScriptManager , UpdatePanel. ASP.NET 2.0 AJAX. ASP.NET provides built-in AJAX functionality Two flavors: Built into some Data Controls Limitations ScriptManager & Update Panel Very flexible.
E N D
AJAX ASP.NET MIS 424 Professor Sandvig
Today • ASP.NET AJAX • Controls: built-in properties • ScriptManager, UpdatePanel
ASP.NET 2.0 AJAX • ASP.NET provides built-in AJAX functionality • Two flavors: • Built into some Data Controls • Limitations • ScriptManager & Update Panel • Very flexible
Server Controls • Built in AJAX functionality • GridView, DetailsView, FormView • Property: AllowSortingAndPagingCallbacks • Benefits • Easy to implement • Limitations: • Controls cannot use templates • Inefficient: retrieves all data and discards extra
UpdatePanel • UpdatePanel • Wrap any server controls • Become AJAX enabled • Benefits • Easy to implement • Flexibility • Mix & match controls • Specify triggers
Update Panel • Disadvantage • JavaScript cannot be tweaked • Fine if it meets your needs • Heavy • All controls are repopulated • Viewstate also sent/received • Example: • Cascading Dropdown: • CarParts.com • AjaxAspNet.aspx
AJAX Toolkit • Ajax Toolkit • Includes several prewritten AJAX & JavaScript scripts
Summary • ASP.NET Ajax • Built into some controls • Sorting and paging • Update Panel will “Ajaxify” all controls • Ajax toolkit • Drag-and-drop AJAX controls • Benefit: • Convenience • Flexibility • Disadvantage: • Inefficient use of bandwidth (speed)