Announcement

Collapse
No announcement yet.

Windows IIS ASP help

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Windows IIS ASP help

    Can ASP detect if a physical file is missing in the local drive (easily)?

  • #2
    In a way, this would work. Err.Number = 0 means the file is there.

    <%
    Set fso = CreateObject("Scripting.FileSystemObject")
    on error resume next
    Set f2 = fso.GetFile("C:\test2.img")

    response.write "Error Number=" & Err.Number

    %>

    EDIT: Oh, this is easier:

    Set fso = CreateObject("Scripting.FileSystemObject")
    if fso.FileExists(Server.MapPath("C:\testfile.img")) then Response.write "The file is there."
    set fso = nothing

    Now, anyone know how to verify if a HTTP link is valid?

    Comment


    • #3
      http://www.devx.com/vb2themax/Tip/18670

      Try there?
      National Sarcasm Society
      "Like we need your support."

      Comment


      • #4
        Wow, nice! That's really simple using a Lib call.

        Comment

        Working...
        X