The view 'Index' or its master was not found

前端 未结 9 1406
南方客
南方客 2020-12-03 16:03

I\'m new to the C# MVC project type and when I created an empty C# MVC project, I noticed the following error:

The view \'Index\' or its master was not found         


        
9条回答
  •  抹茶落季
    2020-12-03 16:24

    I had a virtual directory that wasn't correctly referencing the actual directory. (On Windows) I fixed this by going into IIS (Internet Information Services Manager), and right clicking the virtual directory that wasn't being correctly referenced (In your case, Views). Virtual directories will have this little icon next to them:

    Right click and then select Manage Virtual Directory > Advanced Settings. Ensure the Physical path matches where you think it should be going:

    This isn't going to apply to all cases, but it's a possible match for some instances.

提交回复
热议问题