Recently a colleague asked if I knew how to run multiple DOS commands from the command line. At first I said, no you cannot, only a batch file can do multiple commands. Then I remembered there may be a way and I did a Google search for run multiple commands in DOS and received 324,000 results. I clicked on the first result which is a blog, and got my answer. I also gathered additional information for older windows systems from Computerhope.com.
It so happens that you can separate multiple commands in DOS with an ampersand, "&". So you can do the following: "cd \ & dir" or any other number of multiple commands. Batch files are appropriate for anything complicated. But if all you wanted to do was something simple, just use the "&" and bunch your commands together. This will work in Microsoft Windows 2000 and Windows XP using cmd.exe. The same thing can be done on Microsoft Windows 95, Windows 98 and Windows ME using the pipe "|", such as cd\ | dir
The unix/linux equivalent would be a ";" to separate commands. Did you remember the use of the & in DOS? Do you still use DOS? If you do, what do you use it for?
Quick Tips
- FrugalTech FreeNAS Link from FreeBSD News
- Replacing Parts in Dell D620 Laptop
- "By Google's calculation a new blog is being created every second of every day. The average blog is read by one person." - Eric Schmidt, CEO of Google
Showing posts with label batch. Show all posts
Showing posts with label batch. Show all posts
Subscribe to:
Posts (Atom)
Archive
- 07/20 - 07/27 (1)
- 07/13 - 07/20 (1)
- 06/15 - 06/22 (1)
- 03/23 - 03/30 (1)
- 10/27 - 11/03 (3)
- 03/31 - 04/07 (1)
- 03/03 - 03/10 (1)
- 09/19 - 09/26 (1)
- 05/09 - 05/16 (1)
- 03/28 - 04/04 (1)
- 03/07 - 03/14 (1)
- 02/28 - 03/07 (1)
- 02/21 - 02/28 (1)
- 02/14 - 02/21 (1)
- 02/07 - 02/14 (1)
- 01/31 - 02/07 (1)
- 01/24 - 01/31 (1)
- 01/17 - 01/24 (1)
- 01/03 - 01/10 (1)
- 12/27 - 01/03 (1)
- 12/20 - 12/27 (1)
- 12/13 - 12/20 (1)
- 11/15 - 11/22 (1)
- 11/01 - 11/08 (2)
- 10/25 - 11/01 (2)
- 08/30 - 09/06 (2)
- 08/16 - 08/23 (1)
- 08/09 - 08/16 (2)
- 08/02 - 08/09 (1)
- 07/12 - 07/19 (1)
- 07/05 - 07/12 (2)
- 06/21 - 06/28 (1)
- 06/07 - 06/14 (1)
- 05/17 - 05/24 (1)
- 05/10 - 05/17 (1)
- 05/03 - 05/10 (1)
- 04/12 - 04/19 (1)
- 04/05 - 04/12 (1)
- 03/29 - 04/05 (2)
- 03/22 - 03/29 (2)
- 03/15 - 03/22 (1)
- 03/08 - 03/15 (2)
- 03/01 - 03/08 (3)
- 02/22 - 03/01 (2)
- 02/15 - 02/22 (3)
- 02/08 - 02/15 (1)
- 02/01 - 02/08 (1)
- 01/11 - 01/18 (2)
- 01/04 - 01/11 (2)
- 12/07 - 12/14 (2)
- 11/30 - 12/07 (4)
- 11/23 - 11/30 (2)
- 11/16 - 11/23 (8)
- 11/09 - 11/16 (7)
- 11/02 - 11/09 (4)
