2.2. Select/Delete Text

About this task

  • Select text.
  • Delete text.

Select text

You can use either the mouse or the keyboard to select text and other characters in your script.

Important: Regardless of which method you use, you can select either a portion of one line or a series of whole lines, but you cannot select a portion of one line plus one or more whole lines.

When you select multiple lines and start or end your selection partially through a line, the Program Editor automatically extends the selection to include the entire starting and ending lines.

Options for selecting text include:

  • Text with the mouse.
  • Text with the keyboard.
  • Line with the keyboard.

Text with the Mouse

Procedure

  1. Place the insertion point where you want your selection to begin
  2. Do one of the following.
    • While pressing the left-mouse button
    1. Drag the mouse until you reach the end of your selection.
    2. Release the mouse button.
    • Using the left-mouse button.
    1. Place the mouse pointer in the left margin beside the first line you want to select.
    2. The pointer becomes a reverse arrow, which points toward the line of text.
    3. Click the left mouse button to select a single line.
    4. Press the left mouse button and drag up or down to select multiple lines.
    • While pressing Shift
    1. Place the mouse pointer where you want your selection to end
    2. Click the left mouse button.

    Result: The selected text is highlighted on your display.

    Text With the Keyboard

  3. Place the insertion point where you want your selection to begin.
  4. While pressing Shift, use one of the navigating keyboard shortcuts to extend the selection to the desired ending point.

    Result: The selected text is highlighted on your display.

    Note: When you intend to select an entire single line of text in your script, it is important to remember to extend your selection far enough to include the hidden end-of-line character, which is the character that inserts a new line in your script.

    Line With the Keyboard

  5. Place the insertion point at the beginning of the line you want to select.
  6. Press Shift + Down arrow.

    The entire line, including the end-of-line character, is selected.

  7. Repeat 2 to extend your selection to include additional whole lines of text.
  8. Place the insertion point in that line.
  9. Press Ctrl+Y.
  10. Place the insertion point after the last character on the current line.
  11. Press Delete once to delete the hidden end-of-line character.
  12. Place the insertion point at the start of a line.
  13. Press Backspace.