So, to change the ScriptManager to ToolkitScriptManager in the master page, it ain't easy as Sharepoint will throw the error of unknown server tag: ToolkitScriptManager. To workaround that, we need to add some references in web.config of Sharepoint:
In my Controls tag in web.config, I added an addition mapping for asp tag prefix controls:
<add tagPrefix="asp" namespace="AjaxControlToolkit" assembly="AjaxControlToolkit,
Version=3.0.31106.0, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e" />
What that does is it will add all ajax controls into standard asp tagged controls. For example, we can start using <asp:ToolkitScriptManager in Sharepoint designer, without actually adding any reference on top of the master page. There are more settings you need to add in web.config, refer to Jan Tielen's blog post. Beware of his version numbers as the new version should be 3.0.++.
After solving that, I tried refreshing Sharepoint, then it gave me another error! This time, a never seen before:
could not load type 'system.web.ui.scriptreferencebase' from assembly 'system.web.extensions, version=188.8.131.52, culture=neutral, publickeytoken=31bf3856ad364e35'.
After a bit of googling, it seems like this was because .NET 3.5 framework SP 1 had not been installed on my machine. After installing it, the error was gone.
Then, to use Ajax Controls, I just drag and drop the control onto my page (web part), and Visual Studio will add the reference on top of the page for me:
<%@ Register Assembly="AjaxControlToolkit, Version=3.0.31106.0, Culture=neutral,
If you think this post is useful, please recommend me at the bottom of the page. ;)