• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need help in compiling programs

 
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi friends....

I am getting problem in compiling my programs from command prompt in WINDOW Operating system.
I am giving :

C:\Program Files\Java\jdk1.5.0_06\bin>javac -classpath "C:\Program Files\Apache Software Foundation\Tomcat 5.0\common\lib\servlet-api.jar" -d classes C:\MyProjects\beerV1\src\com\example\web\BeerSelect.java

and output m getting :

C:\MyProjects\beerV1\src\com\example\web\BeerSelect.java:5: error while writing com.example.web.BeerSelect: classes\com\example\web\BeerSelect.class (The system cannot find the path specified)
public class BeerSelect extends HttpServlet {
^
1 error
=======================================================================
Well I have directory structure as MyProjects\beerV1\classes\com\web and MyProjects\beerV1\src\com\example\web where i have put my servlet program.


Till now I have been using "IBM Web Studio Application Developer" for my application development.
But with that i am encountering problems in implement the JSTL ...taglibs programs..
So thot to use the general method to test programs.

Can you please help me ............
thanks,
pooja
 
Ranch Hand
Posts: 236
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You are compiling from C:\Program Files\Java\jdk1.5.0_06\bin.
So you are saying that the class files should go to classes directory under the above.
Are you sure you have classes directory in C:\Program Files\Java\jdk1.5.0_06\bin ?
 
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Try executing it from C:\MyProjects\beerV1\ directory

Command will look likt

C:\MyProjects\beerV1>javac -classpath "C:\Program Files\Apache Software Foundation\Tomcat 5.0\common\lib\servlet-api.jar" -d classes src\com\example\web\BeerSelect.java
 
Puja Verma
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks... Mohd Fuzail and Surendra Nichenametla

I tried executing my program from C:\MyProjects\beerV1\ directory
and its working ......
It has created class file in the beerV1\classes\com\web, as desired.

Once again ...thanks for your help
pooja
 
reply
    Bookmark Topic Watch Topic
  • New Topic