有一个笨的方法,
File te=new File( "c:\\winzip.log ");
te.setReadOnly();
...
File tempFile=new File ("c:\\temp.txt");(将te内容copy to tempFile)....
update tempFile
......
ts.delete()....File te=new File( "c:\\winzip.log ");
将tempFile内容copy to te小心使用这方法,以防数据丢。
我在此显丑了
File te=new File( "c:\\winzip.log ");
te.setReadOnly();
...
File tempFile=new File ("c:\\temp.txt");(将te内容copy to tempFile)....
update tempFile
......
ts.delete()....File te=new File( "c:\\winzip.log ");
将tempFile内容copy to te小心使用这方法,以防数据丢。
我在此显丑了
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货