Click here to Skip to main content
15,879,326 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:

I have tried below in we.config

<location path="Views">
    <directoryBrowse enabled="false" />

But it's still showing me directory lists.

Please help. Thanks in advance
JoCodes 24-Dec-13 0:52am    
Which is your IIS version
srmohanr 24-Dec-13 0:54am    
IIS 7.0

If the IIS version is 7+ it should work as per the configuration already done in web config.
In case IIS 6 , try it in IIS Manager like

Run > inetmgr

go to Navigation in IIS Manager

Features View > Directory Browsing

Actions Pane > click Enable/Disable
Share this answer
srmohanr 24-Dec-13 4:30am    
I have tried, this. But still I am able to access the directory lists
Share this answer
srmohanr 24-Dec-13 6:59am    
I am new to .Net. This is what I have understood from that.
Please rectify, if I commit any error.

location path="Views"
directorybrowse enabled="false"

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