All of us heard of the upcoming ASP.Net 4.0 and Visual Studio 2010 due in Q4 2009 so I thought on listing the highlights on the ASP side.

Core Services

   Extensible Output Caching – adds an extensibility point to output caching that enables you to configure one or more custom output-cache providers

   Auto-Start Web Applications – The auto-start feature provides a controlled approach for starting up an application pool, initializing an ASP.NET application, and then accepting HTTP requests

   Permanently Redirecting a Page – adds a new RedirectPermanent helper method that makes it easy to issue HTTP 301 Moved Permanently responses

   The Incredible Shrinking Session State – introduces a new compression option for both kinds of out-of-process session-state providers. When the compressionEnabled configuration option is set to true, ASP.NET will compress (and decompress) serialized session state by using the .NET Framework System.IO.Compression.GZipStream class.

AJAX Functionality in ASP.NET 4.0

   Client Template Rendering – includes a new template engine for client development that meets the following requirements:

  • Performance — The engine must be able to render a typical number of items using a reasonably complex template before users perceive an interruption in their interaction with the application.
  • Simplicity — The template syntax must be very readable and must be optimized for the most common scenario, namely one-way/one-time binding.
  • Expression language — Templates must support an expression language to go beyond the simplest cases.
  • The expression language should use familiar syntax, ideally JavaScript syntax.
  • Interspersed code and markup — It must be possible to perform conditional rendering or to loop over markup by using code that surrounds HTML.
  • XHTML compliance — The template should be able to render XHTML-compliant markup.
  • Components — When using the template syntax, the developer must be able to instantiate client-side controls and behaviors that attach to HTML elements in the page or within templates

   Instantiating Behaviors and Controls Declaratively –  introduces a way to declaratively instantiate client-side controls and behaviors and attach them to HTML elements

   Live Data Binding – ensures that the target value is automatically updated whenever the source value changes

   Using the Observer Pattern with JavaScript Objects and Arrays – The observer pattern enables an object to be notified about changes that occur in another object. (The term observer pattern is often misused in JavaScript frameworks to describe event handling based on the addHandler method and similar techniques.) ASP.NET 4.0 implements the pattern completely

   The DataView Control – The DataView control can bind to any JavaScript object or array, or to any ASP.NET AJAX component

   The AdoNetServiceProxy Class – enables read-write interaction with ADO.NET Data Services from JavaScript

   The DataContext and AdoNetDataContext Classes – provides full support for change tracking in the browser. This enables complete end-to-end AJAX-based data scenarios

   Refactoring the Microsoft AJAX Framework Libraries – one can now choose whether to load all the javascript libraries or only part of them throught the ScriptManager

Web Forms

   Setting Meta Tags with the Page.Keywords and Page.Description Properties – One of the smaller additions that has been made to ASP.NET 4.0 Web Forms is the addition of two properties to the Page class, Keywords and Description. These two properties represent corresponding meta tags in your page

   Enabling View State for Individual Controls – In ASP.NET 4.0, Web server controls include a ViewStateMode property that gives you control-level granularity over whether view state is enabled. This lets you disable view state by default and then enable it only for the controls that require it in the page

   Changes to Browser Capabilities – includes a feature referred to as browser capabilities providers. As the name suggests, this lets you build a provider that in turn lets you use your own code to determine browser capabilities

   Routing in ASP.NET 4.0 – built-in support for using routing with Web Forms

   Setting Client IDs – The new ClientIdMode property addresses a long-standing issue in ASP.NET, namely how controls create the the id attribute for elements that they render

   Persisting Row Selection in Data Controls – Persisted selection is now supported for the GridView and ListView controls in all projects by using the PersistedSelection property

   FormView Control Enhancements – A new RenderTable property is now available that lets you specify whether the FormView control renders using a table

   ListView Control Enhancements – ListView control does no longer require a layout template.

   Filtering Data with the QueryExtender Control – To make filtering easier, a new QueryExtender control has been added in ASP.NET 4.0. This control can be added to EntityDataSource or LinqDataSource controls in order to filter the data returned by these controls. Because the QueryExtender control relies on LINQ, the filter is applied on the database server before the data is sent to the page, which results in very efficient operations

Dynamic Data

   Declarative DynamicDataManager Control Syntax – The DynamicDataManager control has been enhanced so that you can configure it declaratively, as with most controls in ASP.NET, instead of only in code

   Entity Templates – Entity templates offer a new way to customize the layout of data without requiring you to create a custom page. Page templates use the FormView control (instead of the DetailsView control, as used in page templates in earlier versions of Dynamic Data) and the DynamicEntity control to render Entity templates. This gives you more control over the markup that is rendered by Dynamic Data

   New Field Templates for URLs and E-mail Addresses – ASP.NET 4.0 introduces two new built-in field templates, EmailAddress.ascx and Url.ascx. These templates are used for fields that are marked as EmailAddress or Url with the DataType attribute

   Creating Links with the DynamicHyperLink Control – Dynamic Data uses the new routing feature that was added in the .NET Framework 3.5 SP1 to control the URLs that end users see when they access the Web site. The new DynamicHyperLink control makes it easy to build links to pages in a Dynamic Data site

   Support for Inheritance in the Data Model – Dynamic Data has been modified to understand inherited objects in the data model and to support scaffolding for the inherited tables

   Support for Many-to-Many Relationships (Entity Framework Only) – New ManyToMany.ascx and ManyToMany_Edit.ascx field templates have been added to provide support for displaying and editing data that is involved in many-to-many relationships

   New Attributes to Control Display and Support Enumerations

   Enhanced Support for Filters


Visual Studio 2010 Web Designer Improvements

   Improved CSS Compatibility – The Visual Web Developer designer in Visual Studio 2010 has been updated to improve CSS 2.1 standards compliance

    HTML and JScript Snippets – In Visual Studio 2010, IntelliSense snippets are supported for JScript, alongside C# and Visual Basic, which were supported in earlier versions of Visual Studio

   JScript IntelliSense Enhancements – JScript IntelliSense has been redesigned to provide an even richer editing experience. IntelliSense now recognizes objects that have been dynamically generated by methods such as registerNamespace and by similar techniques used by other JavaScript frameworks. Performance has been improved to analyze large libraries of script and to display IntelliSense with little or no processing delay. Compatibility has been dramatically increased to support nearly all third-party libraries and to support diverse coding styles. Documentation comments are now parsed as you type and are immediately leveraged by IntelliSense 

Web Application Deployment with Visual Studio 2010

   Web Packaging – Visual Studio 2010 uses the MSDeploy tool to create a compressed (.zip) file for your application, which is referred to as a Web package. The package file contains metadata about your application plus the following content:

  • IIS settings, which includes application pool settings, error page settings, and so on.
  • The actual Web content, which includes Web pages, user controls, static content (images and HTML files), and so on.
  • SQL Server database schemas and data.
  • Security certificates, components to install in the GAC, registry settings, and so on.
  • A Web package can be copied to any server and then installed manually by using IIS Manager.
  • Alternatively, for automated deployment, the package can be installed by using command-line commands or by using deployment APIs.

   Web.Config Transformation – For Web application deployment, Visual Studio 2010 introduces XML Document Transform (XDT), which is a feature that lets you transform a Web.config file from development settings to production settings

   Database Deployment – A Visual Studio 2010 deployment package can include dependencies on SQL Server databases. As part of the package definition, you provide the connection string for your source database. When you create the Web package, Visual Studio 2010 creates SQL scripts for the database schema and optionally for the data, and then adds these to the package. You can also provide custom SQL scripts and specify the sequence in which they should run on the server. At deployment time, you provide a connection string that is appropriate for the target server; the deployment process then uses this connection string to run the scripts that create the database schema and add the data

   One-Click Publishing – Visual Studio 2010 also lets you use the IIS remote management service to publish a Web application to a remote server. You can create a publish profile for your hosting account or for testing servers or staging servers. Each profile can save appropriate credentials securely. You can then deploy to any of the target servers with one click by using the Web One Click Publish toolbar. With Visual Studio 2010, you can also publish by using the MSBuild command line. This lets you configure your team build environment to include publishing in a continuous-integration model