Asp.net-mvc – ASP.NET MVC: 404 – File or directory not found. The resource you are looking for

asp.net-mvciis-7windows-server-2003

I recently deployed an ASP.NET MVC application on a Win server 2008, IIS 7 machine. It has MVC installed, and .NET framework 4.5 installed.
Whenever I publish, and try to log in, I get this annoying error:

404 - File or directory not found.
The resource you are looking for might have been removed, had its name changed, or is     temporarily unavailable.

Meanwhile the controller action – Home/Login is intact and the Login.cshtml page is okay. Plus
the web config file has

  modules runAllManagedModulesForAllRequests="true"/>
  compilation debug="true" targetFramework="4.5">
  assemblies>
     handlers>
    remove name="ExtensionlessUrlHandler-ISAPI-4.0_32bit"/>
    remove name="ExtensionlessUrlHandler-ISAPI-4.0_64bit"/>
    remove name="ExtensionlessUrlHandler-Integrated-4.0"/>
    add name="ExtensionlessUrlHandler-ISAPI-4.0_32bit" path="*." verb="GET,HEAD,POST,DEBUG,PUT,DELETE,PATCH,OPTIONS" modules="IsapiModule"  
    /handlers>

So I am wondering what is wrong. It is running under Integrated mode, ASP.NET 4.0 app pool.
Static content and dynamic content are both enabled. I guess you can tell I have gone through most of the posts on this issue.:) Thanks in advance for the answer.

Best Answer

If possible, I would log onto the server that is hosting the application, Open IIS Manager, find your site and click view in browser. This will ensure that you have the URL correct and should give you more debugging information if something is going wrong.