How to run a program shell

  • Thread starter Thread starter KT
  • Start date Start date
K

KT

I wish to run a program shell at logon. When I log on I
would like a program to autostart and when the program
exits window will reboot. Your help will be appreciated.
KT
 
copy these lines below in notepad and name it "restart.bat" and run it or
put it into the users startup folder for a test.

cd c:\windows\system32
calc.exe
shutdown -f -r

In this test bat file you will see that upon login the user will have the
calculator program automatically startup and when
they close it the computer will shutdown and reboot.

If this works just replace "c:\windows\system32" with the directory your
program is in and then replace the entry
"calc.exe" with the program executable of your choice.

HTH

You can have the machine do as you want shutdown, logoff and reboot by
looking at the command prompt "shutdown /?"
for more help.
 

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