Edlin: [line]

Displays the line of text that you specify.

Syntax

[line]

Parameters

line : Specifies the line number you want Edlin.exe to display. To see the number and text of the current line, press ENTER.

?: Displays a list of edlin subcommands.

Remarks

Windows XP does not use this command. It is accepted only for compatibility with MS-DOS files. 

This tool is not available on Windows XP 64-Bit Edition. 

When you type a line number as a command, Edlin.exe displays two lines. The first line contains the number you specified and its associated text. The second line contains the number again, followed by the insertion point. The text on the first line of the display serves as a template for the second line. On the second line of the display, you can press ENTER to cancel the command without changing the text, type replacement text, or edit the line of text. After you edit a line, press ENTER to enter the changes into memory.

 Warning

If you press ENTER while the insertion point is in the middle of a line, Edlin.exe deletes the portion of the line that is between the insertion point and the end of the line.

For information about saving the edited file from memory to a disk by using the e (End) or w (Write) subcommands, see Related Topics.

Examples

In this example, the following file is in memory and ready to edit. When you use the l (list) subcommand at the * prompt, Edlin.exe displays the contents of the file.

1: Dear Mr. Muth: 
2: 
3: Congratulations on your promotion 
4: to the position of Senior Chemical 
5: Engineer. I continue to be most 
6: impressed with your work. 

To edit line 6, type:

6

Edlin.exe displays the following two lines:

6:*impressed with your work. 
6:*_ 

The first line contains the specified line number and its associated text. The second line contains the same line number and the insertion point.

To insert the word "fine" before the word "work" in the previous example, specify that Edlin.exe redisplay a portion of the first line, beginning at the insertion point position on the second line. First, press F2 and type w. Edlin.exe displays up to, but not including, the first "w" in line 6, as follows:

6:*impressed _

Press F2 and type w again. Edlin.exe displays up to, but not including, the next "w" in line 6, as follows:

6:*impressed with your _

Press the INSERT key, type fine, press the SPACEBAR, and then press F3. Edlin.exe displays the edited line, as follows:

6:*impressed with your fine work._

Press ENTER to accept the change.

At the * prompt, type the l (list) subcommand to see the edited file. Edlin.exe displays the following:

1: Dear Mr. Muth: 
2: 
3: Congratulations on your promotion 
4: to the position of Senior Chemical 
5: Engineer. I continue to be most 
6:*impressed with your fine work. 

Formatting legend

FormatMeaning

Italic

Information that the user must supply

Bold

Elements that the user must type exactly as shown

Ellipsis (...)

Parameter that can be repeated several times in a command line

Between brackets ([])

Optional items

Between braces ({}); choices separated by pipe (|). Example: {even|odd}

Set of choices from which the user must choose only one

Courier font

Code or program output

Edlin

Edlin subcommands

Edlin: w (write)

Edlin: e (end)

Command-line reference A-Z



© 2014 Microsoft Corporation. All rights reserved. Contact Us |Terms of Use |Trademarks |Privacy & Cookies