Using CodeWarrior

Creating a HelloWorld.java program

This example is intended to get you started with CodeWarrior. This example assumes that you are working from CDF-PC on campus; if you are working from home, you'll probably want to use C: instead of H: for the hard drive. The instructions for invoking CodeWarrior at home may be different if you're using a different version of CodeWarrior.

This document contains details about how to create a Java program from scratch, or how you can include existing Java files (files that have already been created and exist on your hard drive - you may have downloaded these from the course web site). All steps are the same for these two tasks, except for step 4. Step 4 (a) explains how to create a new Java program, and step 4 (b) explains how to include existing Java program files. In this example, we assume that the Java program will be contained in a single Java file called HelloWorld.java. We will also name our project HelloWorld.

If you are working on take-home quiz 2, you might also find the Quiz 2 CodeWarrior Tutorial helpful.



  1. Invoke CodeWarrior



  2. Create a new project



  3. Tell Java where the main method is



  4. Include Files - create or open Java files



  5. Compile



  6. Run



  7. Closing CodeWarrior



  8. Reopening a Project


Using Windows Explorer

In step 4 (b) it talks about using Windows Explorer to copy files from one directory to another on your computer. It should be noted that this application is not part of CodeWarrior. You can minimize your CodeWarrior application (by clicking on the minus sign at the top right corner of CodeWarrior), and then start up and run a Windows Explorer session as follows:



  • Invoke Explorer



  • The environment



  • Create a New Folder



  • Copying files