How to shutdown computer using Notepad

Author: Ellen Moore
Date Of Creation: 14 January 2021
Update Date: 29 June 2024
Anonim
How to shutdown/turn off your PC using notepad
Video: How to shutdown/turn off your PC using notepad

Content

Notepad is a free Windows text editor that you can use to edit program codes. You can enter some simple Windows commands in Notepad to create a file that will shutdown your computer. Create such a file to quickly shut down your computer or just make fun of someone.

Steps

  1. 1 Open Notepad. This free text editing program is included with all versions of Windows. In Notepad, you can write the simplest code that turns off your computer.
    • To open Notepad, click Start> Programs> Accessories> Notepad. You can also click Start, type notebook and press ↵ Enter.
  2. 2 Enter shutdown.exe -s on the first line. This is a command to shutdown the computer.
  3. 3 Add a timer using a parameter -t. By default, the computer will shutdown after 30 seconds. To change this time, add the parameter -t, and then enter the number of seconds.
    • For example, to turn off the computer after 45 seconds, enter shutdown.exe -s -t 45.
    • To shut down the computer immediately, enter shutdown.exe -s -t 00.
  4. 4 Add your message. To display a message on the computer before the computer shuts down, use the -c... In our example, enter shutdown.exe -s -t 45 -c "Message text... The text must be enclosed in quotation marks.
    • For example, you can specify in the message how long the computer will turn off; to do this, enter shutdown.exe -s -t 45 -c "The computer will shutdown in 45 seconds.".
  5. 5 Click File> Save As. The file must be saved in the BAT format (batch file), the launch of which will turn off the computer.
  6. 6 Open the Save as type menu and select All Files ( *. *) ". Now you can change the file type.
  7. 7 Remove the extension .txt at the end of the file name. Instead, enter .bat.
    • If the extension (in the form of three letters) does not appear, look online for information on how to do it.
  8. 8 Save the file. A file with the extension .bat; the icon for this file will be different from the icon for the text file.
  9. 9 Run the generated file to turn off your computer. The shutdown process will take place in accordance with the rules that you have set.
    • Save open files before turning off your computer.

Warnings

  • If you decide to play a trick on someone, do it at your own peril and risk. Remember that you may be offended or angry.