0
votes

When I run any Ajax control, i am getting the following error:This was written in .net 2.0 and running at .net 3.5.

please help me what is the setting i need to change.

"Error 32 Could not load file or assembly 'System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. D:\DotNet\AJAX\Ajax video\HDI-ACT-Accordion-CS\web.config 30 "

Thanks, Masum

3

3 Answers

1
votes

Looking at the error message, you might have a reference (a mention of) to System.Web.Extensions.dll in your web.config.

Try and remove that line from web.config.

1
votes

If the machine does not have the 2.0 version of the System.Web.Extensions.dll that could be your issue. You may need to re-download/install the .NET 2.0 version of the Ajax extensions from here:

http://www.microsoft.com/downloads/details.aspx?FamilyID=ca9d90fa-e8c9-42e3-aa19-08e2c027f5d6&displaylang=en

1
votes

You have said:

This was written in .net 2.0 and running at .net 3.5.

I assume that what you mean by this is that the site was originally written using ASP .Net 2.0 but that it was upgraded at some point to ASP .Net 3.5. If this is the case then it could be that you have an incorrect reference to version 1 of System.Web.Extensions. This can be remedied by follwoing the steps bellow:

1) In web.config add a reference to System.Web.Extensions v3.5:

<assemblies>
   <add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
</assemblies>

2) In web.config add the following as a child of configuration:

<configuration>
   <!--Some other config-->
   <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
      <dependentAssembly>
         <assemblyIdentity name="System.Web.Extensions" publicKeyToken="31bf3856ad364e35"/>
         <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="3.5.0.0"/>
      </dependentAssembly>
   </assemblyBinding>
</configuration>

As brenden mentions you may also need the correct version of the Ajax Toolkit.