1. Go to Start > Control Panel > System and Security > Administrative Tools and click on the Task Scheduler.
2. From the Action menu in Task Scheduler, click "Create Basic Task..."
3. In the "Create Basic Task Wizard" windows that pops up, Type in a
title and a description. Something basic like "PC Shutdown."
4. Click "Next."
5. On the "Task Trigger" screen, choose the frequency with which
you want the Shutdown PC to run. For nightly shutdown, click on "daily"
and click the Next" button.
6.On the "Daily" screen, enter the date and time you want your PC to shutdown. Click "Next."
7. On the "Action" screen, choose "Start a program" and click "Next."
8. On the "Start a Program" screen, type C:\Windows\System32\shutdown.exe in the "Program/script" text field.
9. In the Add arguments text field type /s.
10. Click "Next."
11. Confirm your settings on the Summary screen and click "Finish."
Now your Windows 7 computer will automatically shutdown at the same time every day/night.