`
edwin492
  • 浏览: 115638 次
  • 性别: Icon_minigender_1
  • 来自: 深圳
社区版块
存档分类
最新评论

No result defined for action and result

    博客分类:
  • SSH
阅读更多

No result defined for action and result

1、validate方法没有通过;

2、页面元素中有重命名时,但后台action类的对应的接收此同名参数的是变量而没有写成数组,这个极有可能,我就碰到过,搞了好久才发现是这个原因


要检查这种错误时,可以
1,在后台action类中重写ActionSupport中的
void addActionError(String anErrorMessage)
void addActionMessage(String aMessage)
void addFieldError(String fieldName, String errorMessage)
这三个方法,在并在其实现代码中设置断点,监控传入的参数,并可获知页面的相关报错具体原因.
2,在页面中加入以下标签,将错误显示出来:
<div style=”color:red”>
<s:fielderror />
</div>

struts2.1.8 必须配置namespace
在2.0中一切OK,没有问题,但是在2.1中确出现了No result defined for action的异常,郁闷了好半天,经过多方查找,原来是在2.1中有一个插件struts2-convention-plugin-2.1.8.jar,这个插件是2.1版本中新添加的默认核心包,这个插件是实现Struts2的零配置,但是这样问题就来了,如果引入就必须引入namespace命名空间,否则就会出现刚才的No result defined for action的异常

分享到:
评论

相关推荐

    jsp\No result defined for action and result input.doc

    ### Struts2框架中“No result defined for action and result input”错误解析及解决方法 #### 错误概述 在Struts2框架中开发Web应用程序时,可能会遇到一个名为“No result defined for action and result input...

    No result defined for action.doc

    在IT领域,尤其是在Web开发中,遇到“No result defined for action”这类错误是常见的问题,尤其当使用Struts2框架时更为突出。此类错误通常指向在控制器(Action)中未正确配置或实现结果集(Result),导致请求...

    struts2 的异常收集

    No result defined for action cn.itcast.user.web.action.UserAction and result error ``` 此异常表明在`struts.xml`中没有为指定的动作定义结果。例如,如果期望动作在发生错误时转向特定的JSP页面,但配置文件...

    a project model for the FreeBSD Project.7z

    There is no defined model for how people write code in FreeBSD. However, Niels Jørgenssen has suggested a model of how written code is integrated into the project. Figure 4-1. Jørgenssen's model ...

    struts2错误集合.txt

    错误信息:“No result defined for action com.upload.UploadAction and result input”。 这个错误通常是由于配置文件中没有正确定义动作的结果导致的。确保在`struts.xml`中为每个动作定义了合适的`result`标签...

    polycom宝利通视频会议软件3.9 2018

    (if you are located in the rest of the world) (each referred to individually and collectively herein as “POLYCOM”), for the SOFTWARE PRODUCT (as defined below) licensed by POLYCOM or its suppliers....

    微软内部资料-SQL性能优化3

    SQL Server never asks for SIX locks directly, they are always the result of a conversion. For example, suppose a transaction scanned a page using an S lock and then subsequently decided to perform a ...

    我的JAVA开发工作笔记

    在提供的内容中提到了一个错误 `No result defined for action com.sxit.smxt.action.XXXAction and result input`。这意味着Struts2框架无法找到对应Action的`input`结果定义。 #### 解决方案: - **检查配置文件*...

    配置struts2常见错误

    No result defined for action ***Action and result success **问题描述**: 当执行某个Action后,出现“没有定义success结果”的错误。 **解决方法**: 这意味着在`struts.xml`中未正确配置`success`结果。为了...

    PMBOK 2008 English Version

    The Project Manager is responsible for the project objectives to deliver the final product that has been defined, within the constraints of project scope, time, cost and required quality. Strengths...

    精心整理的ssh2 一些错误问题的记录(推荐)

    ### 错误八:No result defined for action... and result... 这类错误通常出现在Struts框架中,当在一个动作中定义的结果没有在配置文件(如struts.xml)中正确配置时发生。确保每个动作的结果都在配置文件中有...

    LCTF软件备份VariSpec™ Liquid Crystal Tunable Filters

    For this reason, the functions that handle these actions offer the option of waiting until the action is complete before returning (so-called synchronous operation); although they can be called in an ...

    struts_2.3.12GA_API文档(chm版本)

    Stops the action invocation immediately (by throwing a PauseException) and causes the action invocation to return the specified result, such as Action.SUCCESS, Action.INPUT, etc. void ...

    BURNINTEST--硬件检测工具

    - Minor changes to the No operation error watchdog timer for the CD and Hard disk tests. - Minor correction to the Butterfly seek test. - Video playback trace logging increased. Release 5.3 build ...

    php.ini-development

    of the INI constants (On, Off, True, False, Yes, No and None) or an expression ; (e.g. E_ALL & ~E_NOTICE), a quoted string ("bar"), or a reference to a ; previously set variable or directive (e.g. ${...

    Java邮件开发Fundamentals of the JavaMail API

    framework adds support for typing arbitrary blocks of data and handling it accordingly. This doesn't sound like much, but it is your basic MIME-type support found in many browsers and mail tools ...

    FlexGraphics_V_1.79_D4-XE10.2_Downloadly.ir

    - FIX Add moving block for first and last connector's segments also for non-orthogonal connectors. - FIX Class TPenProp rewrote without TPen delphi object. - FIX In some cases TFlexCurve.Paint ...

    曲线拟合工具CurveExpert 1.0

    + Cascading a large number of windows would sometimes result in some windows being moved off of the screen. Now, the cascade restarts at the top left if a window might be moved off-screen. + The ...

Global site tag (gtag.js) - Google Analytics