Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Aug 2004
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    file path problem

    Hi,
    How come this is not working? if I paste this address
    (FilePath = "\\cbsapp014\qara_docs$\1.pdf") in either Windows Explorer or
    a browser on my pc, It works and I see the pdf document. But my VBScript code
    keeps saying file does not exist. Here's a piece of code


    ==============================================
    FilePath = "\\cbsapp014\qara_docs$\1.pdf"

    if FSO.FileExists(Filepath) Then
    'open file

    Else
    'say file doesn't exist (I alwasy get this)
    ==============================================

    I desperately need an answer. Here's some info about the server.

    the .asp file including the code is in the webserver's root directory
    which is (d:\notes\data\domino\html\). The server is IIS. However, the .pdf file is being accessed through a webshare with path (\\cbsapp014\qara_docs$\1.pdf)but the actual physical path is (d:\quara_docs\1.pdf).

    I want to access it through the webshare (gives me permission control) but I keep getting file doesnt exist when I view the .asp page (works fine from windows explorer or IE.
    What's wrong with the code above?

    Greatly appreciate any help,

  • #2
    Mega-ultimate member
    Join Date
    Jun 2002
    Location
    Winona, MN - The land of 10,000 lakes
    Posts
    1,855
    Thanks
    1
    Thanked 45 Times in 42 Posts
    Possible solution:

    When you're asking for the file, you asking under your rights. When the server askes for the file, it asks under its rights. Does your server have read access to that data share?

  • #3
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you want that file to be accessible via IIS go into the IIS Manager and add a virtual directory which points to the remote server so the file ends up at a URL of http://yourserver/nameofyourvirtuald...remotelocation
    Check out the Forum Search. It's the short path to getting great results from this forum.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •