• Post Reply Bookmark Topic Watch Topic
  • New Topic

java classpath problem  RSS feed

 
Mudra desai
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
javac: file not found: src/com/example/web/BeerSelect.java
its showing me this error. I tries. a lot of sites for suggestion but could nit find anything.please help
Screen-Shot-2017-07-03-at-3.40.13-PM.png
[Thumbnail for Screen-Shot-2017-07-03-at-3.40.13-PM.png]
 
Tim Moores
Saloon Keeper
Posts: 3658
78
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Describe the layout of all involved dircetories and files, which command you're entering, and which directory you're in when entering that command.
 
Mudra desai
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am in Beer-vi directory and I command is:
javac -classpath downloads/apache-tomcat-8.5.15\common\lib\servlet-api.jar:classes:. -d classes src/com/example/web/BeerSelect.java

error:
javac: file not found: src/com/example/web/BeerSelect.java
Usage: javac <options> <source files>
use -help for a list of possible options
Screen-Shot-2017-07-03-at-3.39.55-PM.png
[Thumbnail for Screen-Shot-2017-07-03-at-3.39.55-PM.png]
 
Mohammed Sardar.
Ranch Hand
Posts: 120
1
Java jQuery Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

It seems BeerSelect.java has been misplaced under web-apps\Beer-v1\src\com\..\BeerSelect.java instead Java Resources\src\com\example\web\BeerSelect.java  Place try moving the java file to Java Resources /src. Refer below image.

Kindest Regards
JavaRanch.png
[Thumbnail for JavaRanch.png]
JavaRanch
 
Mudra desai
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!