Forums - C# Corner

Forum guidelines
satish kumar

satish kumar

  • 755
  • 8
  • 35.6k

How to Prevent direct access to files and folders in asp.net

Aug 17 2011 5:20 AM
Hi everyone
can you any one tell me how to prevent files from directory when the user trying to access files directly.
when he tries to access files it should ask login
in my directory i have [.xls, .doc, .pdf files]

how to do this.
if by authentication and authorization how...?
is there any alternate...to do this..?

Answers (2)

Download Free eBooks

SPONSORED BY

Spire.Doc - Free .NET Word API
Use Spire.Doc to create, read, write, print, and convert word documents to OpenXML, RTF, TXT, XPS, EPUB, EMF, HTML, Image and PDF.