Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

can not be able to compile Action Class

 
Jaffery Rab
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I am very new Struts programming, infact trying to run my first struts application, but can not be able to compile Action class. Code is :

getting error message:

My form bean look like this and its already compile and I put .class file in classes directory alredy:

Web.xml look like this:

struts-config.xml look like this:

and I don't know what to put in hansen.playgound.ApplicationResources thats why I left it blank, nothing is in there.
Please help me!!
 
Darryl A. J. Staflund
Ranch Hand
Posts: 312
2
Android Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
Did you specify your classpath for javac?
Darryl
 
Jaffery Rab
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My Class path look like this:
C:\j2sdk1.4.1_03\lib\servlet.jar;C:\jakarta-tomcat-4.1.24\common\lib\servlet.jar;C:\jakarta-tomcat-4.1.24\common\lib\struts.jar

also I am compiling it from my <CATALINA_HOME>/webapps/struts-blank/WEB-INF/src directory.
How can I set classpath for javac ??
 
Darryl A. J. Staflund
Ranch Hand
Posts: 312
2
Android Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
Although you include the JAR files in your classpath, you also need to include the path of your src directory. If you do not, the Javac compiler will not be able to locate and hence compile the Java source files in the src directory. It is not enough that you issue the javac command from within the src directory -- unless the src directory is included in your class path.
You can include the src directory in your classpath by appending it to your CLASSPATH environment variable or by passing it to the javac compiler using the '-classpath' attribute.
Just type 'javac' on a source line by itself for information on the proper syntax on how to do this.
Cheers,
Darryl
[ June 06, 2003: Message edited by: Darryl A. J. Staflund ]
 
Jaffery Rab
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can include the src directory in your classpath by appending it to your CLASSPATH environment variable or by passing it to the javac compiler using the '-classpath' attribute.

I am sorry I am bothering you too much..........
How can I do this can you gimme an example?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic