Solved

Ajaxtoolkit error on IIS7

Posted on 2014-03-31
4
1,192 Views
Last Modified: 2014-04-24
I converted a project from ASP.NET 2.0 to 4.0. It was working fine on development but once pushed to windows server 2008 (IIS 7) it looks like ajaxtoolkit is not being recognized. I do have the ajaxtoolkit.dll in the Bin folder on the server.
I have attached my web.config. A dropdown which uses ajaxtoolkit is not working. Also I get an error on the browser whenever I load the page "object doesn't support this property or method" on the following line on the browser.

<script type="text/javascript">
<!--
Sys.Application.add_init(function() {
  var h = Sys.Application.get_history();
  h.setServerId("_ctl0_MainCenterContent_History1", "_ctl0:MainCenterContent:History1");
})
Sys.Application.add_init(function() {
    $create(Sys.Extended.UI.ModalPopupBehavior, {"BackgroundCssClass":"modalBackground","OkControlID":"_ctl0_ContentLeftS_btnSave","PopupControlID":"_ctl0_ContentLeftS_Panel2","dynamicServicePath":"/CustomerWeb/WebHome.aspx","id":"_ctl0_ContentLeftS_ModalPopupExtender1"}, null, null, $get("_ctl0_ContentLeftS_BtnLaunch"));
});
Sys.Application.add_init(function() {
    $create(Sys.Extended.UI.AutoCompleteBehavior, {"completionInterval":500,"completionListCssClass":"autocomplete_completionListElement","completionListItemCssClass":"autocomplete_listItem","completionSetCount":20,"delimiterCharacters":";, :","firstRowSelected":true,"highlightedItemCssClass":"autocomplete_highlightedListItem","id":"AutoCompleteEx","minimumPrefixLength":1,"serviceMethod":"GetCustomerList","servicePath":"AutoComplete.asmx"}, null, null, $get("_ctl0_MainCenterContent_txtCustomer"));
});
webconfig.txt
0
Comment
Question by:Angel02
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 41

Assisted Solution

by:guru_sami
guru_sami earned 50 total points
ID: 39968148
My first guess was ClientIDMode but I see you have it set in your web.config.
Are you using the ToolScriptManager or ScriptManager?
Also can you try explicitly setting ClientIDMode="AutoID" for your dropdownlist.
0
 
LVL 26

Accepted Solution

by:
Alan Warren earned 450 total points
ID: 39968492
Hi Angel02
did you get the recommended compatible version of ajax controls toolkit for .net framework 4.0?
AJAX RECOMMENDED DOWNLOADS

Respectfully yours,
Alan
0
 

Author Comment

by:Angel02
ID: 39970032
@guru_sami
I am using toolkit script manager in my master page
 <ajaxToolkit:ToolkitScriptManager runat="server" ID="ScriptManager1">
                      </ajaxToolkit:ToolkitScriptManager>
I tried the ClientID in dropdown but it did not work. And there is still error on the page that I mentioned "object doesn't support...."

@Alan Warren
Thank you for the link. I did realize I was using version 3.5. Now I downloaded version 4.1 and out the new dll's in the Bin folder of my project. Is that sufficient? I reloaded the webpage but nothing changed. Still the same error and dropdown doesn't work unless page is refreshed.
0
 

Author Comment

by:Angel02
ID: 40020448
In the sample project that I got from Alan Warren's link, I obtained the following lines in the web.config. That fixed the issue and the webpage works like a charm!

 <httpHandlers>
      <add verb="*" path="AjaxFileUploadHandler.axd"
           type="AjaxControlToolkit.AjaxFileUploadHandler, AjaxControlToolkit" />
      <add verb="*" path="CombineScriptsHandler.axd"
           type="AjaxControlToolkit.CombineScriptsHandler, AjaxControlToolkit" />
    </httpHandlers>
   </system.web>
  <system.webServer>
    <modules runAllManagedModulesForAllRequests="true"/>
    <validation validateIntegratedModeConfiguration="false" />
    <handlers>
      <add name="AjaxFileUploadHandler" verb="*" path="AjaxFileUploadHandler.axd"
           type="AjaxControlToolkit.AjaxFileUploadHandler, AjaxControlToolkit" />
      <add name="CombineScriptsHandler" preCondition="integratedMode" verb="*" path="CombineScriptsHandler.axd"
           type="AjaxControlToolkit.CombineScriptsHandler, AjaxControlToolkit" />
    </handlers>
  </system.webServer>
0

Featured Post

Free NetCrunch network monitor licenses!

Only on Experts-Exchange: Sign-up for a free-trial and we'll send you your permanent license!

Here is what you get: 30 Nodes | Unlimited Sensors | No Time Restrictions | Absolutely FREE!

Act now. This offer ends July 14, 2017.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

jQuery is a JavaScript library that greatly simplifies JavaScript programming. AJAX is an acronym formed from "Asynchronous JavaScript and XML."  AJAX refers to any communication between client and server, when the human client does not observe a…
A phishing scam that claims a recipient’s credit card details have been “suspended” is the latest trend in spoof emails.
This is a high-level webinar that covers the history of enterprise open source database use. It addresses both the advantages companies see in using open source database technologies, as well as the fears and reservations they might have. In this…
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question