Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The Windows operating system contains a built-in command line interpreter that makes it possible for end-users to create simple (and sometimes not so simple) program

The Windows operating system contains a built-in command line interpreter that makes it possible for end-users to create simple (and sometimes not so simple) program scripts in order to automate routine tasks. Your textbook and the article The Command Line Interpreter in Windows (located in your course module) explain a little about how commands are entered and executed in an interpreted language. When you run the command line interpreter (CMD.EXE), the system opens the command window so that you can enter the commands, one-by-one. Each time that you press the enter key, the system executes the line that you just typed.

Working in a command line might seem a little clumsy for someone who is used to using the Windows GUI interface. Some repetitive tasks, such as adding users to a computer or emptying and deleting a group of directories, may be easier to accomplish using the scripting abilities built into cmd.exe.

Practice the commands contained in the article and view the video Creating Batch Files using the Command Interpreter located in your module. Once you have completed this exercise, answer the following questions:

  1. In the Windows GUI, the term folders is used to refer to the directory structure on the disk storage. What are the CLI commands to create and delete a disk directory? What commands list the contents of a directory on the screen?
  2. Windows CLI has a built in help feature. Use the help feature to find out what functions are available using the XCOPY command. Which option switches would you use if you wanted to copy the contents of a directory, including all of the subdirectories and files, and to suppress the display of the filenames while copying the files and directories?
  3. Practice the batch file commands that are illustrated in the module. Make a new folder in your documents directory named Test1. Download the three test files that are included with this activity. Place the files in the new directory Test1.
  4. Create a simple batch file in Notepad that does the following tasks:
    1. Start with the command that suppresses the display of the execution of each batch file command.
    2. Enter the command to create a new directory named Test2 in your documents directory (remember that you should always specify the complete path from the root of the drive to the new directory location).
    3. Use the XCOPY command to copy the files from the Test1 directory into Test2. What might be some other commands that you could use to copy or move the contents of Test1 to Test2?
    4. Enter the command to output the list of files contained in Test2 to a file named List2.txt.
    5. Save the batch file as a text file named MyBatch.bat.

  1. Submit the answers to the questions and a copy of your batch file and the List2.txt file.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Systems Design Implementation And Management

Authors: Peter Rob, Carlos Coronel

6th International Edition

061921323X, 978-0619213237

More Books

Students also viewed these Databases questions