Mohamed Salah
Mohamed Salah

Reputation: 975

Godaddy hosting server error

I am trying to host my website in godaddy its MVC3 .net website after copying deployed version in the server i get the following error:

CS0234: The type or namespace name 'Helpers' does not exist in the namespace 'System.Web'

Source Error:

Line 33:  <pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID">
Line 34:    <namespaces>
Line 35:      <add namespace="System.Web.Helpers"/>
Line 36:      <add namespace="System.Web.Mvc"/>
Line 37:      <add namespace="System.Web.Mvc.Ajax"/>

Any suggestions?

Upvotes: 0

Views: 346

Answers (1)

Darin Dimitrov
Darin Dimitrov

Reputation: 1039130

Make sure that the System.Web.Helpers assembly is registered in the <assemblies> section:

<compilation debug="true" targetFramework="4.0">
  <assemblies>
    <add assembly="System.Web.Abstractions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
    <add assembly="System.Web.Helpers, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
    <add assembly="System.Web.Routing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
    <add assembly="System.Web.Mvc, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
    <add assembly="System.Web.WebPages, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
  </assemblies>
</compilation>

Also contact your hosting provider to ensure that he has ASP.NET MVC 3 installed and that those assemblies are available in the GAC. If this is not the case you may try to bin deploy your ASP.NET MVC 3 application.

Upvotes: 2

Related Questions