delete contents from folder upon login

J

jatman

good afternoon,

is it possible to write a small batch file that will delete the contents of
a folder when a user logs onto xp.

normally i would write a macro in word to do this, but i am experiencing
difficulties and have opted to just delete the contents of the folder when a
user logs on.

the files would be temporary files that need to be saved properly (for file
name and subject lines) before they can be emailed out by Outlook. users
always forget to clean up the folder so sometimes there could be sensitive
information in the folder.

any suggestions on where to start would be appreaciated,

jat
 
M

Mark L. Ferguson

XP has GPEDIT.MSC, which can set a policy to use a "Logon Script" of your
own creation. Knowing the path to the files, there a numerous ways to delete
them.
--delete.bat--
del <PathToFiles>\*.* /q
--end file--
 
J

jatman

thanks Mark, that was a great start. i set up the batch file to run on logoff.

or the script paramaters, i have
%systemroot%\grouppolicy\users\scripts\logoff
is this correct?

i tried to use the del command in just straight dos and also checked out the
site http://www.computerhope.com/delhlp.htm and tired their commands, but it
does not work.

are the scrip paramaters correct, or are they for something else. (i also
tried it with the scrip paramaters blank.) are there any other sites that i
could check out that you know of?

thanks,

jat
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top