Hey everyone, ive been searching through the forums looking for answers but havent found any thus far. I will continue to look but i will just present my problem to you guys since i have an assignment due tommarow.
downloaded and installed JDK 5.0 update 1 from java.sun.com (used defualt directory)
Changed "path" system variable to:
C:\Program Files\Java\jdk1.5.0_01\bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\ATI Technologies\ATI.ACE\
downloaded and installed textpad from this site (defualt directory)
Everything was done in this order. Now when i select tools/compile java
i get the following error.
javac: invalid flag: C:\Documents and Settings\Casey Jones of Death\Desktop\Document1.txt
Usage: javac <options> <source files>
where possible options include:
-g Generate all debugging info
-g:none Generate no debugging info
-g:{lines,vars,source} Generate only some debugging info
-nowarn Generate no warnings
-verbose Output messages about what the compiler is doing
-deprecation Output source locations where deprecated APIs are used
-classpath <path> Specify where to find user class files
-cp <path> Specify where to find user class files
-sourcepath <path> Specify where to find input source files
-bootclasspath <path> Override location of bootstrap class files
-extdirs <dirs> Override location of installed extensions
-endorseddirs <dirs> Override location of endorsed standards path
-d <directory> Specify where to place generated class files
-encoding <encoding> Specify character encoding used by source files
-source <release> Provide source compatibility with specified release
-target <release> Generate class files for specific VM version
-version Version information
-help Print a synopsis of standard options
-X Print a synopsis of nonstandard options
-J<flag> Pass <flag> directly to the runtime system
Tool completed with exit code 2
If anyone can help me figure out what is going on it would be greatly appreciated. Im very new to java and these are the last kind of problems i need thanks a bunch
jdk/textpad deadline tommarow
Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard
- s_reynisson
- Posts: 939
- Joined: Tue May 06, 2003 1:59 pm
First, since this is a fresh install with all the latest and the greatest of both Java and TP I don't think you need to change your path.
Second, Java file names get their names from the class name inside of it. They also have the file ending .java. Document1.txt is not a very good name anyway!
An example, my fav program of all times, Hello World:
Second, Java file names get their names from the class name inside of it. They also have the file ending .java. Document1.txt is not a very good name anyway!
An example, my fav program of all times, Hello World:
If you save that program with any other filename than HelloWorld.java you will get a compile error, just go ahead and try it! I hope this helps!public class HelloWorld
{
public static void main( String args[] )
{
System.out.println( "HelloWorld!" );
}
}
Then I open up and see
the person fumbling here is me
a different way to be
the person fumbling here is me
a different way to be
-
- Posts: 2
- Joined: Mon Jan 31, 2005 1:32 am