Presentation is loading. Please wait.

Presentation is loading. Please wait.

DOS and the Command Line CS 21a: Introduction to Computing I First Semester, 2013-2014.

Similar presentations


Presentation on theme: "DOS and the Command Line CS 21a: Introduction to Computing I First Semester, 2013-2014."— Presentation transcript:

1 DOS and the Command Line CS 21a: Introduction to Computing I First Semester, 2013-2014

2 What is DOS? ► Disk Operating System ► Enables the user to organise data files, load and execute (run) program files ► Entirely text-based, command-line system where the user can type in commands from the keyboard

3 Launching the Command Line ► From the Start menu, choose Run ► Type command or cmd and click OK ► Or: download cmdhere.bat from the course website, place in a folder, and then double-click ► To close the command line, type exit and press

4 A Word of Warning ► With DOS comes power; you can very easily mess up your system if you use powerful commands in the wrong way ► Be EXTREMELY careful when using these commands: ► format ► fdisk ► del / deltree

5 Useful DOS Commands ► dir – display current directory ► use /w or /p if directory has a lot of files ► ? stands for a single digit or letter ► * stands for a combination of digits and/or letters ► cd – change current directory ►. – current directory ►.. – parent directory ► md - make new folder ► copy - copies the to a file called ► del - deletes a file

6 Java Commands ► javac - compile a java program ► java - execute a java program ► javadoc - generate java documentation ► javap - print information about the java class

7 Java Commands ► set path= ;%PATH% - adds the JDK system directory to the existing path variables set path=C:\Program Files\Java\jdk1.6.0_20\bin ► set classpath= - informs Java where class files are located ► (Note: path should include the location of the Java executables; automatically set by cmdhere.bat)

8 DOS Exercise ► Open a command line terminal window ► Create and compile the Hello.java program on your desktop ► Create a " cs21a " subdirectory under C:\Users\User\Desktop ► Copy Hello.java and Hello.class to the "cs21a" directory by using JUST 1 copy command ► Delete the Hello.java and Hello.class files on your desktop


Download ppt "DOS and the Command Line CS 21a: Introduction to Computing I First Semester, 2013-2014."

Similar presentations


Ads by Google