Wrox Programmer Forums
|
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Struts section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old December 21st, 2007, 07:13 AM
Registered User
 
Join Date: Dec 2007
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Strut 1.3.5

Hello all!,

I working with the example named struts-cookbook-1.3.5, and i try compile, the following messages are displayed:

SimpleActionForm.java:23: package org.apache.struts.action does not exist
import org.apache.struts.action.ActionErrors;
                                ^
SimpleActionForm.java:24: package org.apache.struts.action does not exist
import org.apache.struts.action.ActionForm;
                                ^
SimpleActionForm.java:25: package org.apache.struts.action does not exist
import org.apache.struts.action.ActionMapping;
                                ^
SimpleActionForm.java:26: package org.apache.struts.action does not exist
import org.apache.struts.action.ActionMessage;
                                ^
SimpleActionForm.java:33: cannot find symbol
symbol: class ActionForm
public class SimpleActionForm extends ActionForm {
                                      ^
SimpleActionForm.java:81: cannot find symbol
symbol : class ActionMapping
location: class examples.simple.SimpleActionForm
    public void reset(ActionMapping mapping, HttpServletRequest request) {
                      ^
SimpleActionForm.java:109: cannot find symbol
symbol : class ActionMapping
location: class examples.simple.SimpleActionForm
        ActionMapping mapping,
        ^
SimpleActionForm.java:108: cannot find symbol
symbol : class ActionErrors
location: class examples.simple.SimpleActionForm
    public ActionErrors validate(
           ^
SimpleActionForm.java:112: cannot find symbol
symbol : class ActionErrors
location: class examples.simple.SimpleActionForm
        ActionErrors errors = new ActionErrors();
        ^
SimpleActionForm.java:112: cannot find symbol
symbol : class ActionErrors
location: class examples.simple.SimpleActionForm
        ActionErrors errors = new ActionErrors();
                                  ^
SimpleActionForm.java:116: cannot find symbol
symbol : class ActionMessage
location: class examples.simple.SimpleActionForm
            errors.add("name", new ActionMessage("errors.name.required"));
                                   ^
SimpleActionForm.java:121: cannot find symbol
symbol : class ActionMessage
location: class examples.simple.SimpleActionForm
            errors.add("secret", new ActionMessage("errors.secret.required"));
                                     ^
SimpleActionForm.java:126: cannot find symbol
symbol : class ActionMessage
location: class examples.simple.SimpleActionForm
            errors.add("clave", new ActionMessage("errors.clave.required"));
                                    ^
SimpleActionForm.java:131: cannot find symbol
symbol : class ActionMessage
location: class examples.simple.SimpleActionForm
            errors.add("clave", new ActionMessage("errors.dominio.required"));


I hope anybody can help me

 
Old December 24th, 2007, 06:22 AM
Friend of Wrox
 
Join Date: Mar 2007
Posts: 373
Thanks: 0
Thanked 1 Time in 1 Post
Default

Verify that the struts jar file is in class path, the exception clearly says that it couldn't find the action package and other classes, which means the jar file is not available.


- Rakesh
 
Old December 26th, 2007, 01:31 PM
Registered User
 
Join Date: Dec 2007
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hello rakesh_mscit,

Thanks for your information.

The system variables are:

CLASSPATH
.\;%JAVA_HOME%\lib;
C:\Archivos de programa\Controlador JDBC de Microsoft SQL Server 2005\sqljdbc_1.1\esn\sqljdbc.jar;
C:\Archivos de programa\Apache Software Foundation\Tomcat 5.5\webapps\axis\WEB-INF\lib\saaj-api.jar;
C:\Archivos de programa\Java\jre1.5.0_10\lib\servlet.jar;
C:\Archivos de programa\Apache Software Foundation\Tomcat 5.5\common\lib;
C:\Archivos de programa\Apache Software Foundation\Tomcat 5.5\webapps\struts-cookbook-1.3.5\WEB-INF\lib
JAVA_HOME
C:\Archivos de programa\Java\jre1.5.0_10

..and persist the error, but I compling with:

C:\>javac -cp "%classpath%;C:\Archivos de programa\Apache Software Foundation\To
mcat 5.5\webapps\struts-cookbook-1.3.5\WEB-INF\lib\struts-core-1.3.5.jar" C:\PER
SONAL\JAVA\ECLIPSE\TEST\WEB-INF\src\java\examples\simple\SimpleActionForm.java

the .class file can be generate






Similar Threads
Thread Thread Starter Forum Replies Last Post
strut validation frame work issue pkherde Struts 1 June 7th, 2007 11:40 PM
org.apache.strut.util.GenericDataSource elbicho JSP Basics 1 August 23rd, 2003 03:55 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.