Click here to Skip to main content
14,880,638 members
Please Sign up or sign in to vote.
0.00/5 (No votes)

I developed one web application using wcf services in my application.It working fine.But my problem is,when i hosted in iis(my local system),it showing an error like,

Server Error in '/WCFService' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Could not load file or assembly 'System.Web.Extensions, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.

Source Error:

Line 22: <compilation debug="true">
Line 23: <assemblies>
Line 24: <add assembly="System.Web.Extensions, Version=, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
Line 25: <add assembly="System.Data.Linq, Version=, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
Line 26: </assemblies>

Source File: c:\inetpub\wwwroot\WCFService\web.config Line: 24

Assembly Load Trace: The following information can be helpful to determine why the assembly 'System.Web.Extensions, Version=, Culture=neutral, PublicKeyToken=31bf3856ad364e35' could not be loaded.

WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

My web.config file is::

Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
<compilation debug="true">
<add assembly="System.Web.Extensions, Version=, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<add assembly="System.Data.Linq, Version=, Culture=neutral, PublicKeyToken=B77A5C561934E089">

please give me any idea to solve this error



Please go C:\WINDOWS\assembly and check the System.Web.Extensions Assembly Name ,Version,public Key token exists.

If any of these changed then you need to install latest framework.The version Framework 4.0 is not installed in your local system.

Hope this helps...
Try these 2 steps (replace Framework with Framework64 if it's needed):

Go to:

C:\Windows\Microsoft.NET\Framework\v2.0.50727\ or the installed version
and then run:

aspnet_regiis -i
Go to: C:\Windows\Microsoft.NET\Framework\v3.0\Windows Communication Foundation

and then run:

ServiceModelReg.exe -i

I hope this helps.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900