1
votes

I am new to .net and I am having error while i am access to my folder

http://bassano2011.brinkster.net/ works fine

when http://bassano2011.brinkster.net/english/index.aspx

its give me following error:

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.

 Line 37:             ASP.NET to identify an incoming user. 
 Line 38:         -->
 Line 39:       <authentication mode="Windows"/>
 Line 40:       <!--
 Line 41:             The <customErrors> section enables configuration 
4

4 Answers

3
votes

In a hosting environment they generally block the authentication to Windows, as that's need to use their server service to authenticate, witch you don't control and for that, will never work the way you expect.

The error comes up in your web.config configuration witch by IIS flow, it~s the last configuration to take care, as more are in place, normally the IIS it self and the machine.config file that sets the rules for that machine, and it's there that is "said" that you can't use `"Windows" authentication.

To avoid that error, either choose Forms or None as the parameter of your authentication mode.

To read more about authentications, please read the MSDN.

3
votes

If you have configured your website by putting the published website in the wwwroot folder under the inetpub folder in the c: drive. Then, the error message, configuration error allowdefinition='machinetoapplication' beyond application level, may also come if you have not converted your website to an application. To convert the website to an application, you need to open the IIS window-->Right-click your website folder under the Sites node-->Select Convert to Application.

Further, ensure that you have added an application pool for the same.

0
votes

There are two reason for that,

  1. If you have not Configured your application to run on IIS then Create a virtual directory and assign permissions to Application .

2.check whether you are having two web.config file.