首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > JAVA > Java Web开发 >

在使用myeclipse中出现的有关问题

2012-01-26 
在使用myeclipse中出现的问题?在myeclipse中的写了Actionform,在Actionform中的publicActionErrorsvalidat

在使用myeclipse中出现的问题?
在myeclipse中的写了Actionform,在Actionform中的
public   ActionErrors   validate(ActionMapping   mapping,
HttpServletRequest   request)   {
//   TODO   Auto-generated   method   stub
ActionErrors   errors   =   new   ActionErrors();
if((message==null)||(message.length() <1))
{
errors.add(ActionErrors.GLOBAL_ERROR,   new   ActonError( "error.message.required "));}
return   errors;
}
其中add()   函数被在中间用黑线划掉,请问这是原因引起的

[解决办法]
在新版本中不再建议使用的方法
[解决办法]
改成 errors.add(ActionErrors.GLOBAL_ERROR, new ActionMessage( "error.message.required ")); 就可以了。

热点排行