15分买一判断呀! 你好,bobokong(寻找编程的乐趣) 你也在呀,能帮我解决一下么 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 大家帮我解决一下呀:就是这段有问题呀,int iOK=oEreport.executeUpdate(out);//这个地方好像不对但我不知该怎么改呀, if(iOK==1){ JOptionPane.showMessageDialog(null, "保存成功!", "恭喜成功!",JOptionPane.INFORMATION_MESSAGE); } else{ JOptionPane.showMessageDialog(null, "保存失败!", "错误失败!", JOptionPane.ERROR_MESSAGE); } oEreport.executeUpdate(out)这种好像只对sql语句有用吧 out.write( text );out.close();这两句话执行以后,如果没有抛错,应该存盘成功了试一试这样吧,将提示错误的信息放在catch中... out.write( text ); out.close(); // Display the name of the saved directory+file in the statusBar. System.out.println( currFileName ); //int iOK=oEreport.executeUpdate(out); if (currFileName.isExist()) JOptionPane.showMessageDialog(null, "保存成功!", "恭喜成功!",JOptionPane.INFORMATION_MESSAGE); else JOptionPane.showMessageDialog(null, "保存失败!", "错误失败!", JOptionPane.ERROR_MESSAGE); } catch (IOException el) { el.printStackTrace(); JOptionPane.showMessageDialog(null, "保存失败!", "错误失败!", JOptionPane.ERROR_MESSAGE); }... JTable如何设置列的宽度? 如何清除swt中画的线? Java游戏开发的问题 初学用jdk1.4还是jdk1.5? 如何定义一个线程安全的LinkedList对象? 关于public变量的问题 如何实现每30秒就执行一段程序? 如何把JCHEKCBOX 加入到JLIST中 小弟初学JAVA,大家给点建议吧 如何通过不同的按钮调有不同的画图方法? 各位老哥帮帮忙,这个问题。。。呵,呵,我不懂! Application的参数在jdk1.3的命令行下如何设定?
就是这段有问题呀,
int iOK=oEreport.executeUpdate(out);//这个地方好像不对但我不知该怎么改呀,
if(iOK==1){
JOptionPane.showMessageDialog(null, "保存成功!", "恭喜成功!",JOptionPane.INFORMATION_MESSAGE);
}
else{
JOptionPane.showMessageDialog(null, "保存失败!", "错误失败!", JOptionPane.ERROR_MESSAGE);
}
这种好像只对sql语句有用吧
out.close();
这两句话执行以后,如果没有抛错,应该存盘成功了
试一试这样吧,将提示错误的信息放在catch中
.
.
.
out.write( text );
out.close();
// Display the name of the saved directory+file in the statusBar.
System.out.println( currFileName );
//int iOK=oEreport.executeUpdate(out);
if (currFileName.isExist())
JOptionPane.showMessageDialog(null, "保存成功!", "恭喜成功!",JOptionPane.INFORMATION_MESSAGE);
else
JOptionPane.showMessageDialog(null, "保存失败!", "错误失败!", JOptionPane.ERROR_MESSAGE);
}
catch (IOException el) {
el.printStackTrace();
JOptionPane.showMessageDialog(null, "保存失败!", "错误失败!", JOptionPane.ERROR_MESSAGE);
}
.
.
.