指引网

当前位置: 主页 > 编程开发 > ASP >

asp fso创建文件夹

来源:网络 作者:佚名 点击: 时间:2017-08-23 21:44
[摘要] 指引教程为您提供asp fso创建文件夹等资源,欢迎您收藏本站,我们将为您提供最新的asp fso创建文件夹资源
<script>ec(2);</script>

Function CreatePath(fromPath)
 Dim objFSO, uploadpath
 uploadpath = Year(Now) & "-" & Month(Now) '以年月创建上传文件夹,格式:2003-8
 On Error Resume Next
 Set objFSO = CreateObject(Newasp.FSO_ScriptName)
 If objFSO.FolderExists(Server.MapPath(fromPath & uploadpath)) = False Then
  objFSO.CreateFolder Server.MapPath(fromPath & uploadpath)
 End If
 If Err.Number = 0 Then
  CreatePath = uploadpath & "/"
 Else
  CreatePath = ""
 End If
 Set objFSO = Nothing
End Function

------分隔线----------------------------