Electric Type

Multimedia

About Us

News

Help

Introduction to vi

Page 4 — Deleting Text

The next thing I'm going to do is move back up from line 16 and delete an extra line of text. There's a duplicate line reading "x means to delete something," and I've decided it must go.

First, I'd move back up to that line, typing k until I got there. You can delete text one character at a time simply by pressing x. The character that gets deleted will be the one the cursor highlights.

If that seems too tedious, you can type dw, and delete the text a word at a time. Note that vi counts the spaces in between words as words too, so I'd have to type dw nine times to delete the line.

Or you can just wipe out the entire line of text. To do that, just type dd. Since this is the fastest way to do it, I'm going to type:

dd

and the line that my cursor sits in is gone.

next page»


Dynamic HTML  

Frames  

HTML Basics  

Stylesheets  

Tables  

XML  

Javascript  

Database Connections  

Intro To Perl  

HTML 4.0  

User Blogs

Screen Shots

Latest Updates

Contact Us

Valid HTML 4.01!
Valid CSS!

Breadcrumb

© ElectricType
Maintained by My-Hosts.com
Site map | Copyright | Disclaimer
Privacy policy | Acceptable Use Policy
Legal information.