cannot access virtual directory in classic asp

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pankajdeshmukh
    New Member
    • Dec 2012
    • 1

    #1

    cannot access virtual directory in classic asp

    i am trying to access a virtual directory to retrieve file names of files it contains. here is the code:
    Code:
    Set FSO = Server.CreateObject("Scripting.FileSystemObject")
    Dim mapPath
    mapPath=Server.MapPath("http://development/far/")
    Set farFolder = FSO.GetFolder(mapPath)
    the code gives file not found error.
    i am fairly new to asp so do not know where i am going wrong
  • PsychoCoder
    Recognized Expert Contributor
    • Jul 2010
    • 465

    #2
    Is this site running on IIS7? If so using FileSystemObjec t to do this is never going to work because it only works on the physical file system. It does not know about or understand virtual directories - this aspect of your site is managed entirely by IIS.

    It is not a question of permissions it is a question of the directory not physically being there so browsing the physical file system will never see it

    Comment

    Working...