In the past, I've discussed JavaScript and AJAX improvements in VS 2008 JavaScript Intellisense and VS 2008 JavaScript debugging. Here are a few notes on some of the ASP.NET AJAX runtime features released as part of VS 2008 and .NET 3.5, as well as a few important things you need to know when opening an existing ASP.NET AJAX 1.0 project in VS 2008.
ASP.NET AJAX included in .NET 3.5
ASP.NET AJAX 1.0 is released as a single download that can be installed on top of ASP.NET 2.0. Starting with .NET Framework 3.5, all these features become native to ASP.NET, which means you no longer need to download and install a separate ASP.NET AJAX installation file when building or deploying your application.
When you create a new ASP.NET application or website project in VS 2008 that targets the .NET Framework 3.5, VS automatically adds the appropriate AJAX registration settings to your web.config file, and the core ASP.NET AJAX server controls present in your toolbox.
The version of ASP.NET AJAX released with .NET 3.5 has a number of nice improvements - including support for UpdatePanels that can be used with WebParts, support for WCF-based JSON nodes, and support for ASP.NET users using JavaScript. Data, role and login application service support, as well as N bug fixes and performance improvements.
Understanding ASP.NET AJAX Versions
ASP.NET AJAX 1.0 and .NET 3.5 can be installed side by side on the same machine. ASP.NET AJAX 1.0 is implemented in the V1.0 assembly of System.Web.Extensions.dll, while the ASP.NET AJAX implementation included in .NET 3.5 exists in V3.5 of System.Web.Extensions.dll Program concentration. The V3.5 version of System.Web.Extensions.dll is a fully compatible extension set with version 1.0 (which means you can use it without changing any code).
Every ASP.NET application on the machine can choose to use any version of ASP.NET AJAX to build and run. This is configured through the section node in the web.config file, and the version of the System.Web.Extensions.dll assembly that is referenced when the application is compiled (in a website project, these references are the sections registered in the web.config file , and web application projects specify these references through project files).
You'll be able to use VS 2008 to develop applications targeting ASP.NET AJAX 3.5, and use the new VS 2008 multi-targeting support to build ASP.NET 2.0 applications that use ASP.NET AJAX 1.0. In the following section, I'll discuss how to do this.
Important Beta 2 Information
A few days before we released Beta 2 on the web, we discovered an issue with a side-by-side installation of ASP.NET AJAX. If you read my original "VS 2008 and .NET 3.5 Beta 2 Released" blog post, you'll remember the following post-installation patch steps that I specifically pointed out to fix this issue:
You should download and run this batch file. This takes just a few seconds to run and fixes an issue we discovered earlier this week with the version policy of System.Web.Extensions.dll, the assembly that contains ASP.NET AJAX. If you do not run this batch file, existing ASP.NET 2.0 projects built with ASP.NET AJAX 1.0 and VS 2005 will automatically ship the new ASP.NET AJAX version released with .NET 3.5 Beta2. This will work and run fine, but will inadvertently cause your VS2005 application to depend on .NET 3.5. Running this batch file will change the version binding policy for the new System.Web.Extensions.dll assembly, ensuring that you only use the new .NET 3.5 ASP.NET AJAX version when you explicitly build a .NET 3.5 project.
The good news is that this will correct the side-by-side installation issues we discovered, allowing us to safely develop ASP.NET AJAX applications using both VS 2005 and VS 2008 on the same machine.
But there is a problem is that when opening an old ASP.NET 2.0 project for the first time in VS 2008, it will cause VS 2008 to incorrectly detect the version of ASP.NET AJAX used. Specifically, it will cause VS 2008 to think that The current project already uses .NET 3.5. This requires you to take additional steps to correct this issue when opening an existing ASP.NET AJAX 1.0 website project for the first time in VS 2008 Beta2. In the final release of VS 2008, you will not need to take these steps.
Upgrading an ASP.NET AJAX 1.0 application to use ASP.NET AJAX 3.5
When you use VS 2008 to open an existing ASP.NET 2.0 application that uses ASP.NET AJAX 1.0, you can choose to upgrade the application to use .NET 3.5( and the ASP.NET AJAX version included therein).
The VS Web Tools Group recently published a blog post titled "Upgrading ASP.NET AJAX 1.0 Websites and Web Applications to .NET Framework 3.5", which describes step-by-step instructions on how to use VS 2008 Beta2 to implement the upgrade. The good news is that updating an ASP.NET AJAX 1.0 application to .NET 3.5 does not require you to change any code and only takes a few minutes to complete.
As part of upgrading an ASP.NET AJAX 1.0 application to .NET 3.5, you will need to update any compiled ASP.NET AJAX control libraries you may be using. The ASP.NET AJAX Control Toolkit development team has just released the ASP.NET AJAX 1.0 and .NET 3.5 versions of the AJAX Control Toolkit. You can download it here:
"Upgrading ASP.NET AJAX 1.0 Websites and Web Applications to .NET Framework 3.5" 》The blog post discusses how to add the ASP.NET AJAX 3.5 version of the AJAX Control Toolkit to the VS 2008 toolbox.
Building ASP.NET AJAX 1.0 applications with VS 2008 (using multi-targeting)
When you use VS 2008 to open an existing ASP.NET 2.0 application that uses ASP.NET AJAX 1.0, you can also choose not to upgrade to .NET 3.5, but Use the new multi-targeting feature in VS 2008 to build applications using ASP.NET 2.0 and ASP.NET AJAX 1.0.
The VS Web Tools Group recently published a blog post titled "Using VS 2008 to Target ASP.NET AJAX 1.0", which describes step-by-step instructions on how to use VS 2008 Beta2 to achieve this development.
That blog post also includes several manual steps you'll take in Beta 2 to populate the VS 2008 toolbox with ASP.NET AJAX 1.0 and ASP.NET AJAX Control Toolkit server controls. In the final version of VS 2008, we will release an installation package to automate this process, as well as add ASP.NET AJAX 1.0 project and file templates that can be used in VS 2008 for you.
You may be thinking, why use VS 2008 for ASP.NET AJAX 1.0 applications instead of just VS 2005? The advantage is that it allows you to build ASP.NET AJAX 1.0 applications that work on your existing servers ( No need to upgrade them to .NET 3.5 right away), while also allowing you to take advantage of some of the new features of the VS 2008 IDE, like JavaScript Intellisense, JavaScript Debugging, a better WYSIWYG HTML designer, CSS management, and improved code Compiler, unit testing in VS Professional, continuous integration support in TFS, and more.
Conclusion
.NET 3.5 now includes built-in support for all ASP.NET AJAX 1.0 features. I will be writing more blog posts in the future describing how to take advantage of the new features it offers.
You can use VS 2008 to target existing ASP.NET applications developed with ASP.NET AJAX 1.0, or you can target the new version of ASP.NET AJAX built into .NET 3.5. The VS Web Tools Group blog post mentioned above should be helpful for you with step-by-step guidance on these two aspects.
Hope this article is helpful to you.