Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

'AjaxControlToolkit' is undefined Error

I am using the AjaxControlToolkit in VS2005, and it works fine. I do have some issues though, when I go to some pages I have, then click back, I get this JavaScript error:

'AjaxControlToolkit' is undefined

I have searched MSDN forums, and google, and tried many of the solutions, but none have worked. I have tried, EnablePartialRendering="true", and others. Short of rewriting everything and changing the workflow of my application, is there any way to find the root cause of this, or fix it? ­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­­

like image 517
ScaleOvenStove Avatar asked Sep 18 '08 21:09

ScaleOvenStove


People also ask

What is AjaxControlToolkit DLL?

AjaxControlToolkit contains a rich set of controls that you can use to build highly responsive and interactive AJAX-enabled Web applications. AjaxControlToolkit contains more than 40 controls, including the AutoComplete, CollapsiblePanel, ColorPicker, MaskedEdit, Calendar, Accordion, and Watermark controls.

How can I download Ajax Toolkit for Visual Studio 2010?

Open your browser and go to the official website of Ajax toolkit ASP.NET AJAX Control Toolkit. There you will find ASP.NET Ajax Control Toolkit v15. 1. Just click on that and your download will start.


2 Answers

I got this problme fixed but not by setting CombineScripts="false" but by using the solution described in this post.

There have been some changes in the latest version, due to which you have to use Sys.Extended.UI.BehaviorBase instead of AjaxControlToolkit.BehaviorBase in the registerClass call.

like image 180
Danish Avatar answered Sep 22 '22 07:09

Danish


To get around this 'AjaxControlToolkit' is undefined Error, you may also want to ensure that you have CombineScripts set to false in your ToolkitScriptManager configuration. This can be found in your Master page and this solution has worked for me.

<myTagPrefix:ToolkitScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true" EnablePartialRendering="true" SupportsPartialRendering="true" **CombineScripts="false"**>

Note you will want to change myTagPrefix to the tagprefix you are using for AjaxControlToolkit. This is usually defined in asp at the top of an aspx file like this...

<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="myTagPrefix" %>
like image 36
jcpennypincher Avatar answered Sep 21 '22 07:09

jcpennypincher