I am getting a Path not found error when I run my ASP script. I don't think it is a permissions issues as I made sure that the right users have the needed permissions to the folder. I have a windows server on GoDaddy and I have determined what the absolute path to the directory of the folder is by using the request.serverVariables....... This is the absolute path of the folder
C:\Inetpub\vhosts\NAMEOFMYDOMAIN\THEROOT\build-your-own-report\stjreport\temp
With the absolute path above in mnd.. here is my error and code
Microsoft VBScript runtime error '800a004c'
Path not found
/build-your-own-report/stjreport/includes/includes.inc, line 16
<% thisPage = Request.ServerVariables("SCRIPT_NAME") thisPage = Right(thisPageName,Len(thisPage) - InStrRev(thisPage,"/")) session.timeout = 5 webDir = "/stjreport" pdf_path = server.MapPath("/") & webDir & "/pdfs" tmp_path = server.MapPath("/") & webDir & "/temp" Function RoundUp(n) roundUp = Int(n) - CBool(CDbl(n) <> CLng(n)) End Function Sub cleanItUp(tt) set incFS = server.createobject("scripting.FileSystemObject") /*line 16*/ set incFO = incFS.GetFolder(tmp_path) for each incF in incFO.files 'if instr(1,incF.name,".pdf",1) > 0 then set tmpF = incFS.GetFile(incF) if DateDiff("s",tmpF.DateCreated,now) > tt then incFS.deleteFile(tmpF) 'end if next set incFO = nothing set incFS = nothing End Sub Function makeRandomString(incLength) makeRandomString = "" seedStr = "1,N,O,P,Q,3,W,X,Y,Z,$,4,0,A,B,C,D,E,F,8,G,H,I,J,5,6,7,9,K,L,M,R,2,S,U,V,T," rndAry = Split(seedStr,",") rndName = "" For inc = 1 to incLength Randomize iRandom = Int( UBound( rndAry ) * Rnd ) rndName = rndName & rndAry( iRandom ) next makeRandomString = rndName End Function Sub displayMessage (incMsg,incReturnUrl) if Len(incMsg) > 0 then Response.write("<br /><br /><p style='text-align:center; font-family:arial; font_size:larger;'>" & incMsg & "</p>") %><script language="javascript"> alert("<%=Replace(Replace(incMsg,"<br />","\n"),"<br>","\n")%>");<% if Len(incReturnUrl) > 0 then %> top.location.href = "<%=incReturnUrl%>";<% else %> top.history.go(-1);<% end if %></script><% Response.end() end if End Sub Function isPermittedFile(incFileType,incFile) incFile = replace(incFile, "\", "/") if inStr(incFile,"/") > 0 then incAry = split(incFile,"/") incFile = incAry(uBound(incFile)-1) end if if inStr(incFile,".") = 0 then call (displayMessage("Image file: " & incFile & " sounds not to be a recognized image format","")) incFileAry = split(incFile,".") incExt = incFileAry(1) Select Case LCase(incFileType) Case "image" incAllowedStr = ",gif,png,jpg,jpeg,bmp,tiff," Case "document" 'incAllowedStr = ",pdf,doc,docx,txt,rtf,doc,docx,xls,xlsx," incAllowedStr = ",pdf," End Select isPermittedFile = False if inStr(1,incAllowedStr,","& LCase(incExt) &",",1) > 0 then isPermittedFile = True End Function %>