%@ LANGUAGE = VBScript %> <% Option Explicit %> <% if Session("FONTSIZE") = "" then %> <% else %> <% On Error Resume Next Dim path, currentobj, spath, instobj path=UCase(Session("dpath")) spath=UCase(Session("spath")) if spath = "" then spath = Mid(path,1,InStr(path,"/ROOT")-1) Session("spath")=spath end if Set currentobj=GetObject(path) Set instobj=GetObject(spath) Session("SpecObj")=spath Session("SpecProps")="MSDosDirOutput" function writeFSPath(fieldsize,onchangeproc,onfocusproc, onblurproc,hidden,adminonly) On Error Resume Next Dim thispath, fspath, parenttype, parentobj if Session("vtype") = "dir" then thispath = Session("dpath") fspath = "" parenttype = "" Do Until Instr(parenttype, "VirtualDir") <> 0 'we need clear our path not found error.. err = 0 'add our initial whack... fspath = "/" + fspath 'and cyle through the baseobj till we find the next whack, 'building up the path in new name as we go Do Until Right(thispath,1) = "/" fspath = Right(thispath,1) & fspath thispath = Mid(thispath,1,Len(thispath)-1) Loop 'once we're out, we need to lop off the last whack... thispath = Mid(thispath,1,Len(thispath)-1) 'and try to set the object again... Set parentobj=GetObject(thispath) if err <> 0 then parenttype = "" else parenttype=parentobj.KeyType end if Loop fspath = parentobj.Path & "\" & Replace(fspath,"/","\") writeFSPath = fspath else writeFSPath = text("Path",fieldsize,onchangeproc,onfocusproc, onblurproc,hidden,adminonly) end if end function %>