views:

58

answers:

1

Well the title says it all im using a asp.net 4.0 project. My file structure looks like this

RootSite
 -Web.Config
 -WebService (WebApplication)
  -Web.Config

Now the WebService seems to get some parts of the web.config from the RootSite, the problem here is

<configuration><system.webServer>

So i tryed to place this around that section <location path="." inheritInChildApplications="false"> but that had the result of making a httpHandler only to function in the root directory...

So is there any solution to this? i don't understand why my webservice's web.config is inheriting from the root's web.config..

A: 

This is the way web configs work by design. It allows defining common properties at a higher level and custom properties at a lower level

Most of the time, the higher the level, the lesser the number of config sections in the web.config, you may be in a case where your root web.config contains sections that should be defined at a lower level

vc 74
The reason for my error is that i define a http module that is specific for the root application.. the <location inheritInChildApplications="false"> looked like a blessing but as i soon discovered it blocks the access to that part in all sub folders...
Petoj