jsp SmartUpload 上传文件出错

报错代码如下:org.apache.jasper.JasperException:UnabletocompileclassforJSP:Anerroroccurredat... 报错代码如下:
org.apache.jasper.JasperException: Unable to compile class for JSP:

An error occurred at line: 11 in the jsp file: /web/do_upload.jsp
com.jspsmart.upload.SmartUpload cannot be resolved to a type
8: try
9: {
10: String myFileName="";
11: com.jspsmart.upload.SmartUpload mySmartUpload = new com.jspsmart.upload.SmartUpload();
12: mySmartUpload.initialize(pageContext);
13: mySmartUpload.setMaxFileSize(500*1024*1024);
14: mySmartUpload.upload();

An error occurred at line: 11 in the jsp file: /web/do_upload.jsp
com.jspsmart.upload.SmartUpload cannot be resolved to a type
8: try
9: {
10: String myFileName="";
11: com.jspsmart.upload.SmartUpload mySmartUpload = new com.jspsmart.upload.SmartUpload();
12: mySmartUpload.initialize(pageContext);
13: mySmartUpload.setMaxFileSize(500*1024*1024);
14: mySmartUpload.upload();

An error occurred at line: 16 in the jsp file: /web/do_upload.jsp
com.jspsmart.upload.File cannot be resolved to a type
13: mySmartUpload.setMaxFileSize(500*1024*1024);
14: mySmartUpload.upload();
15: for (int i=0;i<mySmartUpload.getFiles().getCount();i++){
16: com.jspsmart.upload.File myFile=mySmartUpload.getFiles().getFile(i);
17: if (!myFile.isMissing())
18: {
19: myFileName=myFile.getFileName();

求各位大神解答,感激不尽
展开
 我来答
840129536
2012-10-21 · TA获得超过220个赞
知道小有建树答主
回答量:302
采纳率:100%
帮助的人:222万
展开全部
看一下前台jsp的form表单有没有加enctype="multipart/form-data"
<form action="upload.action" method="post" enctype="multipart/form-data">
本回答被网友采纳
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
百度网友1a812615e
2012-10-21 · TA获得超过1146个赞
知道小有建树答主
回答量:739
采纳率:66%
帮助的人:419万
展开全部
jar包放到web-inf/lib目录下面了吗???页面上使用page import相关类了吗?
本回答被提问者采纳
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式