aspose file tools*
The moose likes Beginning Java and the fly likes Compiler won't run Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Compiler won Watch "Compiler won New topic
Author

Compiler won't run

John Panos
Greenhorn

Joined: Mar 12, 2008
Posts: 1
I tried using % javac, but can't get anything to work. Should I instead be using javac.exe ? This is a first time install on Windows XP Media home edition. I'm totally new to the java programming world. Thanks for any help

C:\Program Files\Java\jdk1.5.0_15\bin>% javac
'%' is not recognized as an internal or external command,
operable program or batch file.

C:\Program Files\Java\jdk1.5.0_15\bin>javac.exe
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

-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
Henry Wong
author
Sheriff

Joined: Sep 28, 2004
Posts: 18896
    
  40

C:\Program Files\Java\jdk1.5.0_15\bin>% javac
'%' is not recognized as an internal or external command,
operable program or batch file.


The "%" is the command prompt (for many unix shells). You are not supposed to type that part in....


Anyway, it does look like "javac" worked. You just now need the parameters to tell it what to compile.

Henry


Books: Java Threads, 3rd Edition, Jini in a Nutshell, and Java Gems (contributor)
Jelle Klap
Bartender

Joined: Mar 10, 2008
Posts: 1773
    
    7

Quick tip:

You should seriously consider avoiding the use of white spaces in path names, especially if you're absolutely new to Java.
Once you get to the point where you start learning about class paths, they'll cause you more than enough headaches without the added complexity of having to worry about incorrect path references due to white spaces.
The Program Files folder then is not the most optimal (although default) installation location for the JDK.


Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Compiler won't run