求助!~~~

01831124 2004-05-08 08:17:56
本人现在用JSP做一个留言板,在运行文件PostMsg.jsp中,出现了下例错误:
500 Servlet Exception
Note: sun.tools.javac.Main has been deprecated.
/empty/PostMsg.jsp:15: Class _empty.FileWriter not found.
FileWriter fw = new FileWriter(path + "\\DataFile\\Message.inc", true);
^
/empty/PostMsg.jsp:15: Class _empty.FileWriter not found.
FileWriter fw = new FileWriter(path + "\\DataFile\\Message.inc", true);
^
/empty/PostMsg.jsp:18: Class _empty.BufferedWriter not found.
BufferedWriter bw = new BufferedWriter(fw);
^
/empty/PostMsg.jsp:18: Class _empty.BufferedWriter not found.
BufferedWriter bw = new BufferedWriter(fw);
^
Note: I:\jsp\doc\WEB-INF\work\_empty\_postmsg__jsp.java uses or overrides
a deprecated API. Recompile with "-deprecation" for details.
4 errors, 2 warnings
--------------------------------------------------------------------------------
Resin 2.1.4 (built Fri Aug 2 14:16


PostMsg.jsp文件其中一段代码:
001 <%@ page contentType="text/html; charset=GB2312"%>
002 <HTML>
003 <HEAD>
004 <TITLE>访客留言版</TITLE>
005 </HEAD>
006 <BODY>
007 <CENTER>
008 <FONT SIZE = 5 COLOR = blue>访客留言版</FONT>
009 </CENTER>
010 <HR>
011 <%
012 String path = request.getRealPath(".");
013 //取得目前目录在伺服端的实际位置
014
015 FileWriter fw = new FileWriter(path+ "\\DataFile\\Message.inc",true);
016 //建立FileWrite对象,设置由fw对象变量引用, 并以Append方式写入资料
017
018 BufferedWriter bw = new BufferedWriter(fw);
019 //建立BufferedWriter对象,并设置由bw对象变量引用
请教各位大哥大姐,这是怎么回事呀??
...全文
9 回复 点赞 打赏 收藏 举报
写回复
回复
切换为时间正序
当前发帖距今超过3年,不再开放新的回复
发表回复
相关推荐
发帖
Web 开发
加入

8.0w+

社区成员

Java Web 开发
申请成为版主
帖子事件
创建了帖子
2004-05-08 08:17
社区公告
暂无公告