Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Re-Built PC / IIS Virtual Folder / .NET / Error allowDefinition='MachineToApplication'

1 view
Skip to first unread message

David Elliott

unread,
May 26, 2003, 11:22:20 PM5/26/03
to
I had previously created a virtual folder and added FrontPage Server
Extension. The local path was D:\Dave\Programming\CSharp. Under this
directory I created all my different projects. At this point,
everything was peachy.

Until, I had to rebuild my machine and re-install all my software.
After I got everything back installed, I started IIS and created a
virutal folder and pointed it to the directory listed above. I tried
to start development on my projects again. At this point I got

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 23: "Forms", "Passport" and "None"
Line 24: -->
Line 25: <authentication mode="Windows" />
Line 26:
Line 27:

I looked through the past 20,000 posting in this group and didn't see
anything matching my situation. I did see several that said to make
sure that there is an Application name and Execute Permissions set to
Scripts only. I have checked, double, checked and triple checked
these settings and sill get the error page listed above.

I have stopped and started the Default Web Site in IIS, rebooted, and
jumped up and down waving my hands in the air. Much to no avail.

PLEASE HELP !!!!! and please CC: so I don't miss it.

Dave
DavidE...@BellSouth.net


Ken Schaefer

unread,
May 26, 2003, 11:38:04 PM5/26/03
to
Is the folder marked as an application root in the IIS MMC Snapin? (it
should look like a little 3D box with a globe half coming out)

Can you post lines 15-25 of the web.config file that is causing the problem?

Cheers
Ken

"David Elliott" <DavidE...@BellSouth.net> wrote in message
news:afm5dv82cjs1686me...@4ax.com...
: I had previously created a virtual folder and added FrontPage Server

:
:
:
:
:
:

David Elliott

unread,
May 27, 2003, 12:15:44 AM5/27/03
to
>Is the folder marked as an application root in the IIS MMC Snapin? (it
>should look like a little 3D box with a globe half coming out)
I believe so. Looks like a gray box with flaps open with green globe.

I have included the web.config file with the line noted as the
problem.

Also, not to confuse the problem, I just tried debugging using Debug
-=> Start, and I get the following message and it won't load the page.

Error while trying to run project: Unable to start debugging on the
web server. The project is not configured to be debugged. For ASP.NET
project, verify that you have a valid project file called "Web.config"
for the URL specified and 'debug' is set to "true" in that file.
Would you like to disable future attempts to debug ASP.NET pages for
this project?

Like I mentioned in the first message, all this was working before I
re-installed everything. The debug is set to true in the web.config,
the project properties -=> Configuration properties page has the
conditional compilation constance DEBUG;TRACE defined and generate
debugging information is TRUE

Let me know what else you might need. More the willing to provide it.

Thanks,
Dave

============================================================
<?xml version="1.0" encoding="utf-8" ?>
<configuration>

<appSettings>
<add key="dbAccessConnString"
value="server=(local);database=EventRegistration;integrated
security=SSPI" />


<!--
data source=DAFFYDUCK;initial
catalog=EventRegistration;integrated security=SSPI;" +
"persist security
info=False;workstation id=DAFFYDUCK;packet size=4096"
-->

</appSettings>
<system.web>

<!-- DYNAMIC DEBUG COMPILATION
Set compilation debug="true" to enable ASPX debugging.
Otherwise, setting this value to
false will improve runtime performance of this application.
Set compilation debug="true" to insert debugging symbols
(.pdb information)
into the compiled page. Because this creates a larger file
that executes
more slowly, you should set this value to true only when
debugging and to
false at all other times. For more information, refer to the
documentation about
debugging ASP .NET files.
-->
<compilation
defaultLanguage="c#"
debug="true"
/>

<!-- CUSTOM ERROR MESSAGES
Set customError mode values to control the display of
user-friendly
error messages to users instead of error details (including
a stack trace):

"On" Always display custom (friendly) messages
"Off" Always display detailed ASP.NET error information.
"RemoteOnly" Display custom (friendly) messages only to
users not running
on the local Web server. This setting is recommended for
security purposes, so
that you do not display application detail information to
remote clients.
-->
<customErrors
mode="RemoteOnly"
/>


**********************************************************************
HERE IS THE PROBLEM
**********************************************************************
<!-- AUTHENTICATION
This section sets the authentication policies of the
application. Possible modes are "Windows", "Forms",
"Passport" and "None"
-->
<authentication mode="Windows" />

**********************************************************************
**********************************************************************

<!-- APPLICATION-LEVEL TRACE LOGGING
Application-level tracing enables trace log output for every
page within an application.
Set trace enabled="true" to enable application trace
logging. If pageOutput="true", the
trace information will be displayed at the bottom of each
page. Otherwise, you can view the
application trace log by browsing the "trace.axd" page from
your web application
root.
-->
<trace
enabled="false"
requestLimit="10"
pageOutput="false"
traceMode="SortByTime"
localOnly="true"
/>

<!-- SESSION STATE SETTINGS
By default ASP .NET uses cookies to identify which requests
belong to a particular session.
If cookies are not available, a session can be tracked by
adding a session identifier to the URL.
To disable cookies, set sessionState cookieless="true".
-->
<sessionState
mode="InProc"
stateConnectionString="tcpip=127.0.0.1:42424"
sqlConnectionString="data source=127.0.0.1;user
id=sa;password="
cookieless="false"
timeout="20"
/>

<!-- GLOBALIZATION
This section sets the globalization settings of the
application.
-->
<globalization
requestEncoding="utf-8"
responseEncoding="utf-8"
/>

</system.web>

</configuration>

David Elliott

unread,
May 27, 2003, 12:46:28 AM5/27/03
to
I aught to mention as well, when I re-installed everything I went
ahead and formatted the drives for NTFS. Before I was using VFAT.

Thanks,
Dave

Ken Schaefer

unread,
May 27, 2003, 12:52:09 AM5/27/03
to
This is odd. It is usual to see that type of error message pointing at the
<authentication> section because you can only have one authentication type
per application (you can't have, for example, forms authentication for one
folder, and windows authentication for a different folder). Some people
don't realise this, and so they don't mark their folder as a new application
root, and then they get the error you are seeing.

Have you tried:
a) rebooting?
b) clearing out ASP.Net's temporary files folder (to force recompilation)?

Cheers
Ken


"David Elliott" <DavidE...@BellSouth.net> wrote in message

news:djp5dv0spkvanpnif...@4ax.com...
: >Is the folder marked as an application root in the IIS MMC Snapin? (it

David Elliott

unread,
May 27, 2003, 8:29:23 AM5/27/03
to
Rebooted this morning. Deleted all files that were generated under
bin bin\debug bin\release obj obj\debug obj\release

Did Build -=> Rebuild Solution Built fine. Still won't run. Get
the same error when I run it and the same message when I try to debug
it.

Cheers,
Dave

David Elliott

unread,
May 27, 2003, 10:04:37 PM5/27/03
to
After messing with this for the past day and a half, I have finally
reslolved this issue.

There are 2.... I SAID "TWO" ... places that you have to make sure
that you have set up correctly when working with the virtual
directory.

1) First Place -- The actual Virtual Directory
2) Drill down the Virtual Directory to your project directory

You will have to RIGHT click and select PROPERTIES for each of these
folders.

Make sure you have an Application name created, if not hit create.
Select Execute Permissions to be Script only.

BOTH FOLDERS SHOULD LOOK LIKE A BOX WITH A GLOBE COMING OUT OF IT.

Cheers,
Dave

Ken Schaefer

unread,
May 27, 2003, 11:02:17 PM5/27/03
to
Hi David,

Your project root needs to be an application.
I just (maybe naively) assumed that your virtual directory was the project
root.

If your virtual directory is *not* a project root, it does not need to be an
application.

Cheers
Ken


"David Elliott" <DavidE...@BellSouth.net> wrote in message

news:i968dvsbatkm3429l...@4ax.com...
: After messing with this for the past day and a half, I have finally

: >
: >
: >
: >
: >
:
:


0 new messages