This is a definate case of needing the user profile hive cleanup tool installed and running on the machine. The profile is deleting on logoff, however these files are in use and cannot be deleted. If the Hivve cleanup is already installed it may be worth using a modified version of the script above on machine startup to clean all these out each time the computer boots. you could use
Originally Posted by Gibbo
On Error Resume Next
Set fso = CreateObject("Scripting.FileSystemObject")
strPath = "C:\Documents and Settings\"
userexcludelist = "Administrator,All Users,Default User,localservice,networkservice,"
Set f = fso.GetFolder(strPath)
' Loop through all subfolders
For Each fldrItem in f.SubFolders
fldrName = fldrItem.name
If Right(strPath,1) <> "\" Then
Pathfinder = strPath & "\" & fldrName
Pathfinder = strPath & fldrName
If InStr(1, ".00", fldrName, 1) Then
set obtainfolder = fso.GetFolder(Pathfinder)
' Clean up objects
Set fso = Nothing
Set fc = Nothing
Thanks for that. I usually just run a DELPROF batch file on a server every week or two.
The machines have the User Profile Hive Cleanup Tool installed though.