Save the user-defined class files in either a folder or as a compressed (.zip or .jar) file.
Open a command line terminal, such as "cmd.exe" in Windows. Set the directory to the hard drive on which the program is stored, such as "C:>."
Enter the command "set CLASSPATH=" without quotation marks followed by the exact directory the class is in. Specify the exact location if the class is saved as a compressed file. For example, "C:>directory/classes" if the class files are uncompressed or "C:>directory/classes/class.jar" if they are compressed.
Type "set CLASSPATH=" without quotation marks to clear the classpath.