I am having a problem moving large amounts data to a sharepoint server due to file path length.
Below is the script I have but it not going to work because it looks for two seperate values only. I need one that will check the entire path and filename and if it exceeds the value I out in then it will record the filepath and file name to a log file.
I need a little help,
Const ForWriting = 2
StartFolder = "C:restore"
LogFile = "C:256Length.log"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objLogFile = objFSO.OpenTextFile(LogFile, ForWriting, True)
Set objFSO = Nothing
Set ArrFiles = objFSO.GetFolder(Folder).Files
For Each File In ArrFiles
IF Len(File.name) > 50 THEN objLogFile.WriteLine File
IF Len(Folder) - instrrev(Folder,"") > 256 THEN objLogFile.WriteLine Folder
Set ArrSubFolders = objFSO.GetFolder(Folder).SubFolders
For Each SubFolder In ArrSubFolders
October 9, 2008 9:08 PM
October 10, 2008 2:18 PM