sastowe
13 years agoSuper Contributor
rename folder
Is there an bug in TC 7.2 that prevents a folder rename? I have this code:
sPath = Project.Variables.sOutputRoot
If aqFileSystem.Exists(sPath) Then
sNewPath = aqFileSystem.ExcludeTrailingBackSlash(sPath) & Replace(Cstr(Now()), "/", "")
sNewPath = Replace(sNewPath, ":", "")
bSuccess = aqFileSystem.RenameFolder(sPath, sNewPath)
end if
aqFileSystem.CreateFolder sPath
bSuccess is returning false. The folder is not renamed. When I attempt to rename it in windows explorer, it renames fine. What am I doing wrong? Thanks
S
sPath = Project.Variables.sOutputRoot
If aqFileSystem.Exists(sPath) Then
sNewPath = aqFileSystem.ExcludeTrailingBackSlash(sPath) & Replace(Cstr(Now()), "/", "")
sNewPath = Replace(sNewPath, ":", "")
bSuccess = aqFileSystem.RenameFolder(sPath, sNewPath)
end if
aqFileSystem.CreateFolder sPath
bSuccess is returning false. The folder is not renamed. When I attempt to rename it in windows explorer, it renames fine. What am I doing wrong? Thanks
S