문제

I have a website which uses .net framework 4.5. Using Visual Studio 2013, I have no issues to run it. However, when I publish it, I get the following error message: "the file '/Views/Shared/Admin.Master' doesn't exists.", but it does exists.

Linha 1:  <%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Admin.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>
Linha 2:  
Linha 3:  <asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">

Any idea about it, if I need to do something before publishing, or if I need to configure something in IIS? Thanks a lot.

도움이 되었습니까?

해결책

I faced the same issue, the application build and run correctly on visual studio 2013, but give that error when publishing.

To fix that I changed the build action of the master-page from None to Content

다른 팁

Probably IIS issue. Go to your IIS, go to your website. Once there, in the IIS tab, find Authentication. Open it. Enable ASP.NET Impersonation.

It happens to me sometimes. Is a problem of rights

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top