How to edit the content in cmd.exe?

With cmd.exe, when something's wrong with what I typed? What edit option can I do? I can use arrow key to move cursor one by one, but it would be great if there's a key for

  • Move the cursor to the start of line
  • Move the cursor to the end of line
  • Move the cursor by the word not by character both directions (forward/backward)
  • Delete the word (not a character) under the cursor.

Or, what would be other useful keys for editing?


I know you can do three of the four you requested:

  • Move the cursor to the start of line: Home
  • Move the cursor to the end of line: End
  • Move the cursor by the word not by character both directions (forward/backward): Ctrl + <- or Ctrl + ->

Esc - clears line (like Ctrl+U in bash). F7 shows you current session history. F3 - completion from previous command. F4 - delete to character. So you can place cursor at the beginning of word hit F4 and than character that will delimit your deletion.