wood burning stoves*
The moose likes Struts and the fly likes confusing compile error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "confusing compile error" Watch "confusing compile error" New topic
Author

confusing compile error

Pranav Bhatt
Ranch Hand

Joined: Mar 20, 2006
Posts: 284
Hi am having two java classes, one form and other action in same dir.The dir structure is -:
D:\apache-tomcat-5.5.20\webapps\Sandeep\WEBINF\src\roseindia\web\struts\action.

My LoginForm.java is as-:


It already got compiled and am having a LoginForm.class file in same dir.

Am having my action class in same dir as below-:

But when i'am trying to compile LoginAction.java am getting an error as-:

cannot find symbol
symbol: class LoginForm
location: class roseindia.web.struts.action.LoginAction


As am having the class file of LoginForm in same dir as LoginAction and am importing the package too, still am getting this error. Please help

[ January 28, 2008: Message edited by: pranav bhatt ]
[ January 28, 2008: Message edited by: pranav bhatt ]
Brent Sterling
Ranch Hand

Joined: Feb 08, 2006
Posts: 948
What directory are you compiling from? You should be compiling from your "src" directory and you might need to add "." to your classpath (the -cp param to javac).

- Brent
Pranav Bhatt
Ranch Hand

Joined: Mar 20, 2006
Posts: 284
Thanks it really helped, i had kept my src folder inside WEB-INF and was wrongly compiling.
Thanks again
 
 
subject: confusing compile error
 
Similar Threads
struts
Error: creating bean of class (HELP THE NEWBE)
returning multiple values in a web service
struts
problem in Developing Struts small Apllication