• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

javac complications

 
caleb wiggins
Greenhorn
Posts: 8
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have my bin path right but when i try to compile it gives me this readout

javac: file not found: BeerSong.java
usage: javac <options><source files>
use -help for a list of possible options

i was just wondering if any one else has had this problem and could help me out i had it working just the other day and now its doing this any and all help is much appreciated
 
Martijn Verburg
author
Bartender
Posts: 3275
5
Eclipse IDE Java Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by caleb wiggins:
i have my bin path right but when i try to compile it gives me this readout

javac: file not found: BeerSong.java
usage: javac <options><source files>
use -help for a list of possible options

i was just wondering if any one else has had this problem and could help me out i had it working just the other day and now its doing this any and all help is much appreciated


It's telling you that it can't find the file BeerSong.java, is BeerSong.java in the same directory as where you are running javac from?
 
caleb wiggins
Greenhorn
Posts: 8
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i dont think they are how do i change that?

the file is saved in a notepad doc. the other is in a seperate folder

thanks
 
marc weber
Sheriff
Posts: 11343
Java Mac Safari
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use the command cd to change directories. For example, if your file is in a directory called "myjava," type...

C:\>cd myjava
 
Gaurav Chauhan
Greenhorn
Posts: 27
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i am sure that java source file is not in the current directory. Check the location of the .java file and use CD COMMAND to move to that folder and then try to compile.

Today i noticed a classmate of mine was having the same problem.
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24204
34
Chrome Eclipse IDE Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Also be absolutely sure that you haven't created a file named "BeerSong.java.txt"; Notepad is all too happy to do that for you.
 
Ulf Dittmer
Rancher
Pie
Posts: 42966
73
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Also be absolutely sure that you haven't created a file named "BeerSong.java.txt"; Notepad is all too happy to do that for you.

What can you expect if you combine coffee and beer - being just a simple text editor, it must get confused...
 
caleb wiggins
Greenhorn
Posts: 8
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i changed the directories and got the same result so does this have something to do with the update that i downloaded? or am i just doing something wrong and thank you for all your guys help
 
Ankit Garg
Sheriff
Posts: 9497
22
Android Google Web Toolkit Hibernate IntelliJ IDE Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
your file must be saved ad BeerSong.java.txt

Open the file in notepad and choose File-->Save As
Then Enter the name of the file "BeerSong.java" including the double quotes.
Also remember to keep the Capitalization correct i.e. save the file as BeerSong.java and not beersong.java or beerSong.java...
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic