简体   繁体   中英

Could not load type 'namespace._default' after publishing to IIS server

After getting my app working . I published it to the IIS and got the following error :

Server Error in '/Library' Application.

Parser Error

Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately. 

Parser Error Message: Could not load type 'go._default'.

Source Error: 


Line 1:  <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="default.aspx.cs" Inherits="go._default" %>
Line 2:  
Line 3:  

Source File: /library/go/default.aspx    Line: 1 

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.34009

How can I resolve this error? FYI: I only have filesystem access to this server. I published it from VS to the location \\\\Servername\\Library\\go .

EDIT : I forgot to mention that I did check the bin folder and it has three files in it, two .dlls for packages I added via nuget, and a go.dll .

As I was using a publishing to a sub-folder of a larger website, the bin files that were uploaded were being put in \\Library\\go\\bin , but the server was looking for them in \\Library\\bin .

Creating a \\Library\\bin folder and copying the .dlls there resolved the problem. If someone would like to comment on how I can rewrite the path in the Inherits= to keep them in the \\Library\\go\\bin folder, that would be appreciated.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM