Logon script to delete TEMP files
Posted on 2004-08-19
I have a Windows 2000 Server SP4 / XP Pro SP1 network, one domain.
I need to create an automated mechanism to delete TEMP files in Windows XP workstations. The two folders I need to target are (everything within this folders should be deleted):
C:\Documents and settings\Current_domain_user_name\Local settings\Temp
I also need to delete all files of type *.rtf *.doc and *.tmp (only this type of files, not folders or any other file type) from:
C:\Documents and Settings\Current_domain_user_name\Program files\Microsoft\Word
I would like to add a logon script to a GPO, so that everytime the user logs in, the delete action takes place, before starting any programs.
I have no knowledge of VBS. Could somebody help me with the script?
Thanks in advance,