Click here to Skip to main content
15,891,428 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have a new windows server 2012. I have iis 8 and added the roles that I needed. I also have .NET 4.5 framework in place. I wrote the web app in VS 2010 with c#. It is a 4.0 framework. I went step by step on adding the web app to the server and to iis 8. When I type in the web address I get this error:

HTML
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level.  This error can be caused by a virtual directory not being configured as an application in IIS.

Source Error:


Line 36:     <pages maintainScrollPositionOnPostBack="true"/>
Line 37:     <customErrors mode="Off" defaultRedirect="Oops.aspx"/>
Line 38:     <authentication mode="Forms">
Line 39:       <forms loginUrl="/Login.aspx"/>
Line 40:     </authentication>


Source File: C:\inetpub\wwwroot\fpapp2013\web.config    Line: 38

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


Is there any way for me to fix this? What else do I need?
Posted

I can think of two problems:
1. You are working with Virtual Directory - in that case turn it into an application
2. Form Authentication not enabled in IIS - http://technet.microsoft.com/en-us/library/cc771077(v=ws.10).aspx[^]
 
Share this answer
 
Comments
Computer Wiz99 27-Mar-14 14:03pm    
Kornfeld Eliyahu Peter, Well, I know it is not VD. I am not using it. I will check out 2 though. Thanks for that.
Kornfeld Eliyahu Peter helped me to find my issue and I found another issue when I did that. I had two copies of the same web app in the same folder. Removed one and the other worked. Now have a issue with Crystal Reports which is not a problem.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900