No result defined for action com.nynt.action.ManageAction and result input 问题原因:

1)、 在action类中定义的一个return "input";在xml文件里没有东西接收。

           举例说明:

                     struts.xml 文件:

   <package name="file" namespace="/file" extends="struts-default">
 
      <action name="inputFile" class="action.FileAction" method="inputFile">
        <result name="success">/index.jsp</result>
      </action>

  </package>

action类文件:

public String inputFile(){
        System.out.println(hh);
        return "input";
    }

此时会报这样的异常

2)、struts拦截器无法将前台类型与后台类型匹配报出异常,此时进不了后台

举例说明:
        jsp页面:
           <form action="file/inputFile.action" method="post" enctype="multipart/form-data">
            <input type="text" name="hh" value="aa"/>
          <hr/>
          <input type="submit" value="上传"/>
          </form>

      action类文件:

              private int hh;

             public String inputFile(){
                  System.out.println(hh);
                 return "success";
            }

        

           action 中 aa 为 int 类型有 setter 和g etter 方法,此时报出此异常

              这是因为struts的拦截器没有办法将value里面的“aa”强制转化成int类型

     假设jsp页面有两个<input type="text" value="bb" name="hh"/>  name值同样
        里面的类型都是能够强制转化成 int 的,可是struts的拦截器没有办法拼接
        所以也会报出类型不匹配错误,即这个异常。

No result defined for action com.nynt.action.ManageAction and result input问题的更多相关文章

  1. No result defined for action com.lk.IndexAction and result success

    意图访问一个 /es/index.action 竟然出现: [SAE ] ERROR [05-11 13:54:32] [http-80-5] com.opensymphony.xwork2.util ...

  2. no result defined for action

    1.no result defined for action .......and result input    或者 no result defined for action .......and ...

  3. Struts 2.x No result defined for action 异常

      这是我跑struts2的第一个例子,跑的也够郁闷的,这个问题烦了我几个钟... 2011-5-10 10:10:17 com.opensymphony.xwork2.util.logging.co ...

  4. HTTP Status 404 - No result defined for action com.hebky.oa.classEntity.action.EntitysAction and result input

    在开发中总遇到这个问题,No result defined for action:原因:Action中的属性值为空的时候,Struts2的默认拦截器会报错,但是又找不到input的Result,不能够 ...

  5. Struts2问题,已解决No result defined for action and result input

    struts2.1.8 必须在struts.xml中配置namespace属性 如果你在2.0中一切OK,但是在2.1中确出现了No result defined for action的异常,就是在因 ...

  6. validators配置要点及No result defined for action报错解决方案

    在做JavaEE SSH项目时,接触到validators验证. 需要了解validators配置,或者遇到No result defined for action 这个错误时,可查阅本文得到有效解决 ...

  7. struts异常:No result defined for action

    问题描述: No result defined for action com.freedom.funitureCityPSIMS.controller.login.CheckAction and re ...

  8. SSH配置struts校验发生No result defined for action actions.AdminLoginAction and result input

    配置struts校验发生No result defined for action actions.AdminLoginAction and result input,但是登录,success.jsp, ...

  9. Messages: No result defined for action cn.itcast.oa.test.TestAction and result SUCCESS

    Struts Problem Report Struts has detected an unhandled exception: Messages: No result defined for ac ...

随机推荐

  1. 『PyTorch』第十一弹_torch.optim优化器

    一.简化前馈网络LeNet import torch as t class LeNet(t.nn.Module): def __init__(self): super(LeNet, self).__i ...

  2. dp练习(11)——石子并归

    1048 石子归并  时间限制: 1 s  空间限制: 128000 KB  题目等级 : 黄金 Gold 题解       题目描述 Description 有n堆石子排成一列,每堆石子有一个重量w ...

  3. 决策树ID3算法实现

    决策树的ID3算法基于信息增益来选择最优特征,于是自己实现了一把,直接上代码. """ CreateTime : 2019/3/3 22:19 Author : X Fi ...

  4. java使用HttpClient

    HttpClient常用的包有两个 org.apache.http.client以及org.apache.commons.httpclient 我常用的是org.apache.http.client. ...

  5. 在EO中对数据的重复性进行验证

    只有在数据提交到EO中的时候才会执行set方法进行验证. 如果想要实现实时验证,可以在输入参数的地方添加事件,但是无需为此事件创建方法. 我的理解: 1.我们在页面上对内容进行修改的时候,OAF框架仅 ...

  6. turbine源码分析

    turbine源码分析 1.turbine架构设计 一切从InstanceDiscovery模块开始,该模块提供所有的主机信息.它会定期的发送更新,ConnectionManager负责创建连接到主机 ...

  7. String为什么不可变

    转载:http://www.importnew.com/7440.html https://www.cnblogs.com/leskang/p/6110631.html 什么是不可变对象? 众所周知, ...

  8. SQL Server 调优系列基础篇 - 性能调优介绍

    前言 关于SQL Server调优系列是一个庞大的内容体系,非一言两语能够分析清楚,本篇先就在SQL 调优中所最常用的查询计划进行解析,力图做好基础的掌握,夯实基本功!而后再谈谈整体的语句调优. 通过 ...

  9. OPENSHIFT MYSQL使用Navicat远程连接

    1.安装OpenShift的一个叫RHC的远程管理客户端:https://developers.openshift.com/en/getting-started-windows.html 注意ruby ...

  10. Swift语法笔记

    Guard guard是一种条件判断语句,可以类比if.assert.如果条件不符合,guard的else语句就运行,从而退出这个函数. 具体写法如下: func fooGuard(x: Int?) ...