局域网内文件复制
这是我写的代码:
Set FSO = CreateObject("Scripting.FileSystemObject")
SourceFilesNumber = DateDiff("d", lpStartDatetime, lpEndDatetime)
For i = 0 To SourceFilesNumber
SourceFileName = Format(DateAdd("d", i, lpStartDatetime), "yyyymmdd") & ".hd"
SourceFullPath = lpSourcePath & "" & SourceFileName
ImportFullPath = lpTargetPath & "" & SourceFileName
FSO.CopyFile SourceFullPath, lpTargetPath, True
Next
运行时报“拒绝的权限”,请高手指点,是哪搞错了。
[解决办法]
你先把 lpSourcePath & "" & SourceFileName的内容显示出来,
然后前面加\\,贴到"运行"里面看看能否打开网络路径再说