Month: October 2012

Installing/Configuring AjaxControlToolKit through NuGet

I see many questions has been asked regarding installation/configuration of latest version of AjaxControlToolKit in ASP.NET, Experts-Exchange etc., forums. So i thought of writing an blog post on this.

One of the best community tool set available for ASP.NET WebForms developers is AjaxControlToolKit. Microsoft is making sure that this Ajax control tool kit is updated frequently, to make developers task easier!

In this article, i will show you how to configure AjaxControlToolKit through NuGet. Believe me it’s pretty simple process and moreover it’s fast. It’s just avoid the downloading of the package, extracting it and copying it to the Visual Studio and configuring it etc.,

With NuGet, setting up the AjaxControlToolKit in Visual Studio development environment is never so easy.

NOTE: I’m explaining this article using Microsoft Visual Studio 2010 Professional, since most of the users are working in this IDE.

Let’s get our hands dirty….

1.  Let’s create a new ASP.NET Empty Web Site.

image

image

2.  We are done creating a empty website. Now we will configure AjaxControlToolKit through NuGet.

3.  Right click on the web site and select Manage NuGet Packages

image

4. It will invoke Manage NuGet packages dialog.

image

5.  Now search for “ajaxcontroltoolkit” keyword in the textbox on the right side top corner. It will list you the latest version of AjaxControlToolKit.

image 

6.  Click on Install button to install the AjaxControlToolKit.

image

7.  Once it’s done, close this dialog.

image 

8.  Now if you open the web.config file, you can see the AjaxControlToolKit already registered.

image

9. We are done with the setup. Add a ASP.NET web page, and we will test this by adding an control from AjaxControlToolKit.

image

 

NOTE: You should use Toolkit ScriptManager control, instead of Ajax ScriptManager controls, which you can observe in the above code!

10.  Now it’s time to test. I know, you are successful.

Through NuGet, Not only AjaxControlToolKit, there are many more community developed tools available, which i leave it for you explore.

Finally, NuGet made the developer task very easy!

Happy Web Programming…

Thanks