HTTP Error 500.19 - Internal Server Error
The requested page cannot be accessed because the related configuration data for the page is invalid.
Detailed Error Information
Module DefaultDocumentModule
Notification ExecuteRequestHandler
Handler StaticFile Error
Code 0x800700b7
Config Error Cannot add duplicate collection entry of type 'add' with unique key attribute 'value' set to 'Default.aspx' Config File \?\C:\inetpub\wwwroot\web.config Requested URL http://localhost:80/testiis/ Physical Path D:\Work\Development\Tutorials\TestIIS\ Logon Method Anonymous Logon User Anonymous
Config Source
<files>
<add value="Default.aspx" />
</files>
It looks like you are marking the same Site (Default Web Site) as also an application called /testiis/.
You should know that the Site in itself is an application "/" also called Root, and what is happening is that you are creating a "nested application" pointing to the same directory, causing essentially everything inside the web.config (\inetpub\wwwroot) to be duplicated since the inheritance is based on virtual namespace, in other words IIS merges the configuration files at:
"/web.config"
and
"/testiis/web.config"
which are the same file causing this duplicate problem. What you should do instead is create a folder called Testiis under \inetpub\wwwroot\ and edit your application to point to that directory instead.
User contributions licensed under CC BY-SA 3.0