permaculture playing cards
The moose likes Tomcat and the fly likes problem with struts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "problem with struts " Watch "problem with struts " New topic

problem with struts

Eldo Zacharia

Joined: Nov 08, 2004
Posts: 5
hi ,
I am very much new to struts i have a problem compiling and building struts application .. i have followed the standard directory structure ..buti get the errors below during compilation this is the classpath i have set in the environment variable section (windows xp)
C:\j2sdk1.4.\jre\lib\rt.jar;.;C:\ProgramFiles\Tomcat\common\lib\servlet.jar;.;C:\struts\jakarta-struts-1.1-b2\lib\struts.jar;.;C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\classes

and i use the following .bat file on the cmd line to complie

set cp = C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\lib\struts.jar
set cp =%cp%;C:\Program Files\Tomcat\common\lib\servlet.jar
set classpath=%classpath%;cp
javac -d ..\..\..\classes *.java

Iam doing anything wrong plz let me know if iam

anyone help.

this is the output on the cmd window
C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\src\com\miniHr>set_classpath

C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\src\com\miniHr>set cp = C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\li

C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\src\com\miniHr>set cp =;C:\Program Files\Tomcat\common\lib\servlet.jar

C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\src\com\miniHr>set classpath=C:\j2sdk1.4.0\jre\lib\rt.jar;.;C:\Program Fi
les\Tomcat\common\lib\servlet.jar;.;C:\struts\jakarta-struts-1.1-b2\lib\struts.jar;.;C:\Program Files\Tomcat\webapps\Min

C:\Program Files\Tomcat\webapps\MiniHr\WEB-INF\src\com\miniHr>javac -d ..\..\..\classes *.java cannot resolve symbol
symbol : class ActionFoward
location: package action
import org.apache.struts.action.ActionFoward;
^ cannot resolve symbol
symbol : class HttpRequest
location: class com.miniHr.SearchAction
HttpRequest request,
^ cannot resolve symbol
symbol : class HttpResponse
location: class com.miniHr.SearchAction
HttpResponse response)throws Exception
^ cannot resolve symbol
symbol : class ActionFoward
location: class com.miniHr.SearchAction
public ActionFoward execute(ActionMapping mapping,
Roel De Nijs

Joined: Jul 19, 2004
Posts: 8411

what do you get if you do a print of your classpath-variable after you do your initializations? e.g. with

also, i guess

has to be changed into

SCJA, SCJP (1.4 | 5.0 | 6.0), SCJD
I agree. Here's the link:
subject: problem with struts
It's not a secret anymore!