Can I run a batch file when a user logs off?

  • Thread starter Thread starter A. FJ
  • Start date Start date
A

A. FJ

I want to run a bat file when our users exit. Is there a registry key that
I can put the reference to the bat file?

Thanks.
 
If this is Windows 2000 look into group/local policies, depending on if you
are in a domain or not.

hth
DDS W 2k MVP MCSE
 
A. FJ said:
I want to run a bat file when our users exit. Is there a registry key that
I can put the reference to the bat file?

Hi

For Win2k/WinXP Pro, this is done by using a Group Policy Computer (GPO)
Configuration Logoff and/or Shutdown script. The GPO can be activated manually
with gpedit.msc.

From the Start menu Run dialog, open: gpedit.msc

for logoff script, under "User Configuration",
open Windows Settings\Scripts (Logon/Logoff)
(double click, Add...).

for shutdown script, under "Computer Configuration",
open Windows Settings\Scripts (Startup/Shutdown)
(double click, Add...).

More info in Tip 2147 in the 'NT Reg Hacks' at http://www.jsiinc.com

JSI Tip 2147. Windows 2000 Startup/Shutdown, Logon/Logoff scripts?
http://www.jsiinc.com/sube/tip2100/rh2147.htm



--
torgeir
Microsoft MVP Scripting and WMI, Porsgrunn Norway
Administration scripting examples and an ONLINE version of the 1328 page
Scripting Guide:
http://www.microsoft.com/technet/community/scriptcenter/default.mspx
 

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

Back
Top