自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Closed

Closed

  • 博客(22)
  • 收藏
  • 关注

Struts一些技巧的纪录

1。一表单多按钮的问题,有关button和submit的name属性在getParameter的区别 如果我用type=submit name="" value=""的形式可以在servlet中成功用getparameter获得到底是哪个按钮被按下了但是现在我想在submit前作表单验证, 所以改成了type=button name="" value="" ,然后在js里验证后submit, ...

2006-05-23 17:26:00 54

原创 Struts一些技巧的纪录

1。一表单多按钮的问题,有关button和submit的name属性在getParameter的区别 如果我用type=submit name="" value=""的形式可以在servlet中成功用getparameter获得到底是哪个按钮被按下了但是现在我想在submit前作表单验证, 所以改成了type=button name="" value="" ,然后在js里验证后submit

2006-05-23 17:26:00 877

Oracle中Sequence的一些知识点

1。Oracle的Squence有两个属性,nextval和currval,可以在Sql语句中调用。但是编程时发现,在一个Connection中,只有出现过nextval之后才可以调用currval。比如:select seq.currval from tbl;在今天的实验中是不成功的;而select seq.nextval, seq.currval from tbl;就可以通过2。由上,获取...

2006-05-22 16:22:00 73

原创 Oracle中Sequence的一些知识点

1。Oracle的Squence有两个属性,nextval和currval,可以在Sql语句中调用。但是编程时发现,在一个Connection中,只有出现过nextval之后才可以调用currval。比如:select seq.currval from tbl;在今天的实验中是不成功的;而select seq.nextval, seq.currval from tbl;就可以通过2。由上,

2006-05-22 16:22:00 1010

java.sql.SQLException: ResultSet is closed 的一种解决

碰到这个问题应该不是第一次了,现在才知道其中的一个原因。我在关闭数据库时,总是习惯性地只关闭ResultSet,并且认为那样的话,connnection and statement也会自动关闭的。而事实是,正好相反,JDBC的层次是,Connection一旦关闭,其他两个就自动关闭了。这个与我之前看到的有关IO操作的的值是发生了冲突。因为我记得,在IO中,如果用BufferReader包装In...

2006-05-13 14:07:00 304

原创 java.sql.SQLException: ResultSet is closed 的一种解决

碰到这个问题应该不是第一次了,现在才知道其中的一个原因。我在关闭数据库时,总是习惯性地只关闭ResultSet,并且认为那样的话,connnection and statement也会自动关闭的。而事实是,正好相反,JDBC的层次是,Connection一旦关闭,其他两个就自动关闭了。这个与我之前看到的有关IO操作的的值是发生了冲突。因为我记得,在IO中,如果用BufferReader包装

2006-05-13 14:07:00 9471 1

JProgressBar 的基本用法

今天花了很久研究JProgressBar,最后做个总结吧1。JProgressBar的核心函数是setValue(), 这个函数实现了进度条的控制,还自动实现了刷新2。与setValue匹配的是setMaximun和setMinimun的设定。 Java内部应该是有着value/(max-min)这样的计算机制的。3。以上说的是知道界限的进度条,不知道的话,需要用setIndetermina...

2006-05-12 17:15:00 175

原创 JProgressBar 的基本用法

今天花了很久研究JProgressBar,最后做个总结吧1。JProgressBar的核心函数是setValue(), 这个函数实现了进度条的控制,还自动实现了刷新2。与setValue匹配的是setMaximun和setMinimun的设定。 Java内部应该是有着value/(max-min)这样的计算机制的。3。以上说的是知道界限的进度条,不知道的话,需要用setIndeterm

2006-05-12 17:15:00 4833 1

JTable的相关用法

1。设置列名:使用DefaultListTableModel的构造函数DefaultTableModel(Object[] columnNames, int rowCount)           构造 DefaultTableModel,它的列数与 columnNames 中元素的列数相同,并具有 rowCount 个 null 对象值2。设置Table的值:通过DefaultListTab...

2006-05-10 16:35:00 214

原创 JTable的相关用法

1。设置列名:使用DefaultListTableModel的构造函数DefaultTableModel(Object[] columnNames, int rowCount)           构造 DefaultTableModel,它的列数与 columnNames 中元素的列数相同,并具有 rowCount 个 null 对象值2。设置Table的值:通过DefaultListT

2006-05-10 16:35:00 1436

MVC Tips

1. It's for clearer code and more easily extensiblity.2. Three parts: one represents the business information, one the visual representation and one the control mapping between the view and business ...

2006-05-10 11:43:00 69

原创 MVC Tips

1. Its for clearer code and more easily extensiblity.2. Three parts: one represents the business information, one the visual representation and one the control mapping between the view and business

2006-05-10 11:43:00 707

一个form多个sumit按钮

<script type="text/javacript">function funButton1(){document.formName.action="1.htm";formName.submit();}function funButton2(){document.formName.action="2.htm";formName.submit();}</script>...

2006-05-09 21:30:00 321

原创 一个form多个sumit按钮

script type="text/javacript">function funButton1(){document.formName.action="1.htm";formName.submit();}function funButton2(){document.formName.action="2.htm";formName.submit();}script>html> body>   

2006-05-09 21:30:00 1338

Servlet Collaboration

1. Sharing INformation: ServletContextHttpServlet.getServletContext()Sharing with another ServletContext: ServletContext.getContext(String uripath)  //another ServletContext means using the Servlet ...

2006-05-09 10:58:00 50

原创 Servlet Collaboration

1. Sharing INformation: ServletContextHttpServlet.getServletContext()Sharing with another ServletContext: ServletContext.getContext(String uripath)  //another ServletContext means using the Servle

2006-05-09 10:58:00 793

Advanced JDBC Techniques

1. Stored Procedures: CallableStatementSynatax for a procedure that doesn't return a result is {call procedure_name(.., >>)}, Synatax that return a result value is {?= call procedure_name(.., ....

2006-05-09 09:52:00 52

原创 Advanced JDBC Techniques

1. Stored Procedures: CallableStatementSynatax for a procedure that doesnt return a result is {call procedure_name(.., >>)}, Synatax that return a result value is {?= call procedure_name(.., ..)}.

2006-05-09 09:52:00 773

Reusing Database Objects (in Jsp&Servlet)

1. Reusing DB Connections:. generate connection in init() of Servlet and close connection.  Then in doPost()/doGet(), we can do any query.2. Reusing Prepared Statements: Prepared Statement must be th...

2006-05-08 17:54:00 53

原创 Reusing Database Objects (in Jsp&Servlet)

1. Reusing DB Connections:. generate connection in init() of Servlet and close connection.  Then in doPost()/doGet(), we can do any query.2. Reusing Prepared Statements: Prepared Statement must be t

2006-05-08 17:54:00 785

DB Tips

1. ResultSet.getObject() : function for unknown type of fields in DB table2. ResultSet.wasNull(): return true or false depending on whether the last column read was true database null.3. Prepared St...

2006-05-08 09:30:00 51

原创 DB Tips

1. ResultSet.getObject() : function for unknown type of fields in DB table2. ResultSet.wasNull(): return true or false depending on whether the last column read was true database null.3. Prepared

2006-05-08 09:30:00 683

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除