
Top : Computers : Software : Operating Systems : x86 : DOS : Programming : Languages : Batch :
Microsoft Knowledge Base Articles
Websites
Collection of articles on MS-DOS
ftp://ftp.microsoft.com/MISC1/PEROPSYS/MSDOS/KB/
Microsoft Global Product Support Site, featuring access to a searchable Knowledgebase.
site exerpt
Basic Search To use the basic search to search for Knowledge Base articles, just type the keywords that you want to search on in the For field. The maximum search string length is 255 characters. Click the arrow to submit your query....How to Detect a DoubleSpace Drive from a Batch File
http://support.microsoft.com/?kbid=101884
Removing Non-DOS Partitions with Debug
site exerpt
Removing Non-DOS Partitions with Debug View products that this article applies to.Article ID:106419Last Review:November 14, 2003Revision:1.0This article was previously published under Q106419On This PageSUMMARY Introduction Using Debug to Remove a Non-DOS PartitionAPPLIES TOSUMMARYIntroduction There are currently several different versions of MS-DOS in the personal-computer environment, both in...HOW TO: Determine Whether a Drive Is a RAM Drive
site exerpt
How to determine whether a drive is a RAM drive How to determine whether a drive is a RAM driveView products that this article applies to.Article ID:113418Last Review:September 20, 2005Revision:4.0This article was previously published under Q113418On This PageSUMMARYMORE INFORMATION Method 1 Method 2 Method 3 Method 4APPLIES TOSUMMARY There are no C language functions...MS-DOS 6.22 Supplemental Disk: Description & How to Obtain
site exerpt
MS-DOS 6.22 Supplemental Disk: Description and how to obtain Description and how to obtainView products that this article applies to.Article ID:117600Last Review:August 9, 2004Revision:1.0This article was previously published under Q117600On This PageINTRODUCTIONMORE INFORMATION Description How to obtain MS-DOS 6.22 Supplemental Disk 360K Disk 1 Disk 2 Disk 3 MS-DOS 6.22 Supplemental Disk 720K Disk 1 Disk 2APPLIES TOINTRODUCTION...How to Obtain Microsoft Support Files from Online Services
site exerpt
How to obtain Microsoft support files from online services Microsoft support files from online servicesArticle ID:119591Last Review:August 2, 2005Revision:1.2This article was previously published under Q119591On This PageSUMMARY General instructions for downloadingMORE INFORMATION General instructions for downloading Windows files exe Archive files zip MS-DOS files exe Macintosh-based files hqx bin, or...How to Access Environment Variables in an MS-DOS Batch File
site exerpt
How to Access Environment Variables in an MS-DOS Batch File View products that this article applies to.Article ID:121170Last Review:September 30, 2003Revision:1.0This article was previously published under Q121170SUMMARY The article explains how you can access environment variables within MS-DOS batch files. MORE INFORMATION The following example shows how to test for...Redirection Disables REM in Batch Files
site exerpt
Redirection Disables REM in Batch Files View products that this article applies to.Article ID:26281Last Review:May 10, 2003Revision:1.0This article was previously published under Q26281 In Microsoft MS-DOS versions 3.2 and later, redirection has higher priority than the REM command. For example, the following batch file causes the...Differences between COMMAND /C and CALL
site exerpt
Differences between COMMAND /C and CALL View products that this article applies to.Article ID:34768Last Review:May 12, 2003Revision:1.0This article was previously published under Q34768SUMMARY The following information details the differences between using COMMAND /C and CALL. MORE INFORMATION COMMAND /C loads a new copy of COMMAND.COM into...Order of Precedence in Locating Executable Files
site exerpt
Order of Precedence in Locating Executable Files View products that this article applies to.Article ID:35284Last Review:May 10, 2003Revision:1.0This article was previously published under Q35284On This PageSUMMARYMORE INFORMATION COMMAND.COM MS-DOS Versions Earlier Than Version 4.0 MS-DOS Versions 4.0 and Later MS-DOS Versions 5.0 and Later EXEC FunctionAPPLIES TOSUMMARY This article discusses the following...Equal-Sign Characters as Arguments in Batch Files
site exerpt
Equal-Sign Characters as Arguments in Batch Files View products that this article applies to.Article ID:35938Last Review:May 12, 2003Revision:1.0This article was previously published under Q35938 Using batch files in MS-DOS, it is not possible to include an equal sign as an argument to a batch file. The batch...Environment Variable Trailing Spaces Not Truncated
site exerpt
Environment Variable Trailing Spaces Not Truncated View products that this article applies to.Article ID:36605Last Review:May 12, 2003Revision:1.0This article was previously published under Q36605SUMMARY When setting environment variables, the following commands produce different environment variables: SET FIRST=one SET FIRST =two MORE INFORMATION The command SET now displays...Correct Testing Precedence of Batch File ERRORLEVELs
site exerpt
Correct Testing Precedence of Batch File ERRORLEVELs View products that this article applies to.Article ID:39585Last Review:May 12, 2003Revision:1.0This article was previously published under Q39585SUMMARY When you use multiple IF ERRORLEVEL statements in batch files, the order in which the ERRORLEVELs are tested numerically is important. The correct...MS-DOS: Batch File Labels Are Not Case Sensitive
site exerpt
MS-DOS: Batch File Labels Are Not Case Sensitive View products that this article applies to.Article ID:39627Last Review:November 26, 2003Revision:1.0This article was previously published under Q39627SUMMARY The labels of batch files, which are interpreted with the MS-DOS COMMAND.COM command interpreter, are not case sensitive. For example, the following labels,...How to Use Environment Variable Substitution in Batch Files
site exerpt
How to Use Environment Variable Substitution in Batch Files View products that this article applies to.Article ID:41246Last Review:May 10, 2003Revision:1.0This article was previously published under Q41246SUMMARY A feature new to the Microsoft MS-DOS packaged product is the ability to use environment variables in batch files. These variables can be...Using Batch Files with the FOR Batch Command
site exerpt
Using Batch Files with the FOR Batch Command View products that this article applies to.Article ID:43075Last Review:September 30, 2003Revision:1.0This article was previously published under Q43075SUMMARY If a batch file is used as the command in a FOR batch command, the FOR batch command only calls the batch file...Setting the MS-DOS Errorlevel in a Program
site exerpt
Setting the MS-DOS Errorlevel in a Program View products that this article applies to.Article ID:57658Last Review:May 12, 2003Revision:1.0This article was previously published under Q57658SUMMARY This article explains how you can set the errorlevel of a program for use by the MS-DOS batch file IF ERRORLEVEL command. MORE...Only First 8 Characters in a Batch Label Recognized
site exerpt
Only First 8 Characters in a Batch Label Recognized View products that this article applies to.Article ID:63071Last Review:May 12, 2003Revision:1.0This article was previously published under Q63071On This PageSUMMARYMORE INFORMATION Example 1 Example 2APPLIES TOSUMMARY MS-DOS recognizes only the first eight characters of a batch file label; subsequent characters are ignored. NOTE:...Testing If a Drive or Directory Exists from a Batch File
site exerpt
Testing If a Drive or Directory Exists from a Batch File View products that this article applies to.Article ID:65994Last Review:May 12, 2003Revision:1.0This article was previously published under Q65994SUMMARY You can use the IF EXIST statement to check for the presence of a directory. For example, to test for C:WIN and then...Reading Text Files into MS-DOS Environment Variables
site exerpt
Reading Text Files into MS-DOS Environment Variables View products that this article applies to.Article ID:66292Last Review:May 10, 2003Revision:1.0This article was previously published under Q66292SUMMARY This article describes the several steps needed to use the results of a query (using the FIND filter) as a replaceable parameter in...The Four Steps Needed to Make a Hard Disk Usable
site exerpt
The Four Steps Needed to Make a Hard Disk Usable This article was previously published under Q66706SUMMARY To use a hard disk after it has been installed in a computer, the following four requirements must be met: 1.Identify the drive type in the computer's setup program. 2.The drive must be...Rebooting from Within a Batch File
site exerpt
Rebooting from Within a Batch File View products that this article applies to.Article ID:67929Last Review:May 12, 2003Revision:1.0This article was previously published under Q67929SUMMARY The MS-DOS batch language does not provide a means of restarting a system. However, it is possible to restart a system from within...Simulating Wildcards
site exerpt
Simulating Wildcards View products that this article applies to.Article ID:68268Last Review:May 12, 2003Revision:1.0This article was previously published under Q68268SUMMARY You can simulate wildcards with the FOR command for those commands in MS-DOS that do not allow wildcards. The structure of the command...Maximum Line Length and Count for Batch Files & CONFIG.SYS
site exerpt
Maximum Line Length and Count for Batch Files CONFIG.SYS View products that this article applies to.Article ID:69563Last Review:May 12, 2003Revision:1.0This article was previously published under Q69563On This PageSUMMARYMORE INFORMATION Batch Files CONFIG.SYS FileAPPLIES TOSUMMARY This article contains information on the maximum number of lines and line length allowed for batch files...Testing for a Specific Error Level in Batch Files
site exerpt
Testing for a Specific Error Level in Batch Files View products that this article applies to.Article ID:69576Last Review:May 10, 2003Revision:1.0This article was previously published under Q69576SUMMARY The Microsoft MS-DOS IF ERRORLEVEL number statement checks for error levels of the given number or greater. If you want to check for...Updating the Date and Time Stamps on Files
site exerpt
Updating the Date and Time Stamps on Files View products that this article applies to.Article ID:69581Last Review:May 12, 2003Revision:1.0This article was previously published under Q69581SUMMARY The following MS-DOS command updates the date and time stamps of a file named EXAMPLE without altering the contents of the file. This...Semicolon, Equal Sign As Arguments in Batch File
site exerpt
Semicolon, Equal Sign As Arguments in Batch File View products that this article applies to.Article ID:71247Last Review:May 12, 2003Revision:1.0This article was previously published under Q71247SUMMARY When a semicolon or equal sign is used as a command line argument in a batch file, it is treated as a blank...DOSKEY Macro to Search for File Text
site exerpt
DOSKEY Macro to Search for File Text View products that this article applies to.Article ID:74038Last Review:November 22, 1999Revision:1.0This article was previously published under Q74038SUMMARY The following DOSKEY macro searches all files in the current directory for the message text specified and displays the output a screen at...Pipe (|) After IF EXIST Fails
http://support.microsoft.com/?kbid=74464
Percent Signs Stripped from Batch File Text
site exerpt
Percent Signs Stripped from Batch File Text View products that this article applies to.Article ID:75634Last Review:May 10, 2003Revision:1.0This article was previously published under Q75634SUMMARY Using a percent sign in a batch file requires that two percent signs be specified. For example, the command to display 5 from...Accepting Keyboard Input in Batch Files
site exerpt
Accepting Keyboard Input in Batch Files View products that this article applies to.Article ID:77457Last Review:May 12, 2003Revision:1.0This article was previously published under Q77457On This PageSUMMARYMORE INFORMATION REPLY.COMREFERENCESAPPLIES TOSUMMARY The MS-DOS batch language facility does not provide a means for you to provide input to control program flow....DOSKEY Macros Must Be Executed from the Command Prompt
site exerpt
DOSKEY Macros Must Be Executed from the Command Prompt View products that this article applies to.Article ID:79245Last Review:May 12, 2003Revision:1.0This article was previously published under Q79245SUMMARY It is not possible for a program or batch file to execute a DOSKEY macro. All DOSKEY macros must be executed from the...MS-DOS 6.0 and 6.2: PATH Not Limited to 128 Characters.
site exerpt
MS-DOS 6.0 and 6.2: PATH Not Limited to 128 Characters View products that this article applies to.Article ID:97595Last Review:July 10, 1999Revision:1.0This article was previously published under Q97595On This PageSUMMARYMORE INFORMATION Paths Longer Than 256 Characters If the Path Is in the CONFIG.SYS FileAPPLIES TOSUMMARY In MS-DOS 6.0, 6.2, and 7.0 (included in...Using FTP Batch Scripts.
site exerpt
Using FTP Batch Scripts View products that this article applies to.Article ID:96269Last Review:December 20, 2004Revision:3.1This article was previously published under Q96269SUMMARY FTP (file transfer protocol) is a file transfer utility commonly used with UNIX systems. FTP is capable of using scripts (lists of commands...Missing <CR> after Batch Label Causes Repeat of Last Command
site exerpt
Missing