The Ultimate Windows Server 1002003 System Administrators Guide [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

The Ultimate Windows Server 1002003 System Administrators Guide [Electronic resources] - نسخه متنی

Robert Williams, Mark Walla

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید



BATCH COMMANDS


Batch commands or programs are also commonly known as batch files. They are essentially simplified scripts that support the execution routine or repetitive tasks. A batch program is written as a text file with one or more command lines that are executed sequentially from top to bottom. They are identified by either a .bat or .cmd extension to their file names.

All Windows Server 2003 commands and many applications can be executed from a batch file. To provide greater flexibility, a number of conditional parameters, shown in Table A.25, can be set.


































































Table A.25. Batch File Conditional Commands


Option


Description


call


Permits the execution of another batch program without terminating the parent program.


echo


Turns the display of command action on or off as the batch file is executed. Can also be used to output a message to the screenfor example, "One moment please, while searching..."


endlocal


Ends the setlocal command described below.


for


Executes a specific command for every file in a set of files. Can also be run directly from the command prompt.


goto


Directs Windows Server 2003 to process the line in the batch file that is specified.


if


Processes a command when the specified condition is true; ignored when the condition is not met. The conditions of NOT and ELSE can also be used in combination as part of this option.


pause


Temporarily suspends the batch file until the user takes an action such as pressing a key to confirm an action.


rem


Short for remarks that can be added to the batch file for referencing. These are programming notes that are not executed.


setlocal


Permits the establishment of new localization variables. The localization is retained until the endlocal option resets the environment.


Shift | (pipe)


Modifies the position of parameters in a batch program and permits thestringing together of multiple commands on one line.


>


Outputs command results to the directed point.


()


Groups commands.


||


Executes either the first or next command.


&&


Executes the first command and, if successful, executes the next one.


/ 158