Export (0) Print
Expand All
Dos
Mem
Msg
Expand Minimize
1 out of 1 rated this helpful - Rate this topic

Append

Enables programs to open data files in specified folders as if these files were in the current folder. Used without parameters, append displays the appended directory list.

Syntax

append [;] [[Drive:]Path[;...]] [/x:{on|off}][/path:{on|off}] [/e]

Parameters

;   : Cancels the list of appended folders.

[ Drive : ] Path   : Specifies the drive and folder that you want to append to the current folder. If you do not specify a drive, the current drive is the default. You can specify multiple entries of [Drive:]Path by separating the entries with semicolons.

/x: { on | off } : Specifies whether you want the MS-DOS subsystem to search appended folders when it executes programs. /x:on searches appended folders. /x:off does not search appended folders.

/path: { on | off }   : Specifies whether you want a program to search appended folders for a data file when a path is already included with the name of the file for which the program is looking. The default setting is /path:on.

/e   : Assigns the list of appended folders to an environment variable named APPEND. This command-line option works only the first time you use append after you start your system.

/? : Displays help at the command prompt.

Remarks

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

  • Storing the appended folders list

    You can use the /e command-line option with append to assign the appended folders list to an environment variable named APPEND. To do this, first use the append command with only the /e command-line option. Then, use append again and include the folders you want to append. You cannot specify /e and [Drive:]Path on the same command line.

  • Specifying multiple appended folders

    To append more than one folder, separate multiple entries with semicolons. If you use append with the [Drive:]Path parameters again, the specified folder or folders replace any folders specified in a previous append.

  • Using dir 

    When you type dir to see a list of a directory's files and subdirectories, dir does not include the file names from appended folders.

  • Resolving file name conflicts

    If a file in an appended folder has the same name as a file in the current folder, programs open the file in the current folder.

  • Using append with programs that create new files

    When a program opens a file in an appended folder, the file can be found as if it is in the current folder. If the program saves the file by creating a new file with the same name, the new file is created in the current folder, not the appended folder. You can use append for data files that are not to be modified or that are to be modified without creating new copies of the files. Database programs often modify data files without making new copies. Text editors and word processors usually save modified data files by making new copies. To avoid confusion, avoid using append with these programs.

  • Using /x:on with path 

    When you use /x:on, you can run a program located in an appended folder by typing the program name at the command prompt. Usually, you use the path command to specify folders that contain programs, however, you do not need to use the path command to specify an appended folder that contains programs. MS-DOS subsystem finds a program in an appended folder by following the usual order in which it searches for a program: first in the current folder, then in the appended folders, and then in the search path.

  • Abbreviating /x:on to /x 

    You can abbreviate /x:on to /x. To do this, specify /x:on the first time you use append after you start your system. After that, you can switch between /x:on and /x:off.

  • Using /e with set 

    You can use /e with the set command to display a list of the appended folders. For information about environment variables and set, see Related Topics.

Examples

To allow programs to open data files in B:\Letters and A:\Reports as if the files are in the current folder, type:

append b:\letters;a:\reports

To append the same folders and keep a copy appended folders list in the Windows XP environment (this must be the first time you use append after you start your system), type:

append /e 

append b:\letters;a:\reports

Formatting legend

Format

Meaning

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

Command-line reference A-Z

Set

Dir

Path

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.