第一范文网 - 专业文章范例文档资料分享平台

(完整版)工资管理系统(论文范文_JSP_JAVA_毕业设计)

来源:用户分享 时间:2025/7/19 5:27:31 本文由loading 分享 下载这篇文档手机版
说明:文章内容仅供预览,部分内容可能不全,需要完整文档或者需要复制内容,请下载word后使用。下载word有问题请添加微信号:xxxxxxx或QQ:xxxxxx 处理(尽可能给您提供完整文档),感谢您的支持与谅解。

conn.dbClose(rs); sql=\ conn=null; }

try{

conn=new sqlconn(); catch(Exception exc){} }

rs=null; return ;

sql=\

conn.dbMod(sql);

conn.dbClose(rs);

JOptionPane jop=new JOptionPane();

jop.showMessageDialog(null,\删除成功!\提示信息\ }

catch(Exception se){}

} }

conn=null;

userChoice.remove(userChoice.getSelectedIndex()); nameTxt.setText(\pwdTxt.setText(\

把用户列表的第一用户名赋值给nameTxt文本框

}

public void itemStateChanged(ItemEvent ie){

nameTxt.setText(userChoice.getSelectedItem()); try{

conn=new sqlconn();连接数据库

sql=\语句 }

conn.dbClose(rs); conn=null; }

catch(Exception e){} }

rs=conn.getRs(sql); while(rs.next()){

pwdTxt.setText(rs.getString(\

5.3人员管理功能实现

人员管理部分包括人员信息查询、人员信息添加。当在菜单栏中选择“人员信息查询”后,弹出一界面,输入员工号,按“查询”按钮后,即可查询。如图5.6所示。

图5.6查询员工信息

当在菜单栏选中“添加员工信息”后,弹出一界面,在该界面上有添加、修改、删除、清空、退出五个按钮,要想做某个操作,就输入相应信息,点击对应的按钮来实现。在这举例添加员工信息,如图5.7所示。

图5.7添加员工信息

人员管理功能实现的核心代码如下: 员工信息查询:

public void initChoice() { try{

conn=new sqlconn();

sql=\ }

conn.dbClose(rs); conn=null; }

catch(Exception e){} }

public void actionPerformed(ActionEvent ae){ if(ae.getActionCommand().equals(\退出\

dispose();

rs=conn.getRs(sql); while(rs.next()){

userChoice.addItem(rs.getString(\

if(ae.getActionCommand().equals(\查询\

if(idTxt.getText().equals(\

JOptionPane jop=new JOptionPane();

jop.showMessageDialog(null,\请输入你要查询既内容!\警告\ dispose();

uInfoQue uiq=new uInfoQue(); return ;

}

sql=\* from employees where id='\and

name='\

if(!(idTxt.getText().equals(\

sql=\* from employees where id='\and

name='\

if(!(idTxt.getText().equals(\

sql=\

*

from

employees

where

else

id='\

else

sql=\

*

from

employees

where

name='\

conn=new sqlconn(); try{

rs=conn.getRs(sql); if(rs.next()){

idTxt.setText(rs.getString(\nameTxt.setText(rs.getString(\sSexLab.setText(rs.getString(\sAgeLab.setText(rs.getString(\sPostLab.setText(rs.getString(\sDtmtLab.setText(rs.getString(\

(完整版)工资管理系统(论文范文_JSP_JAVA_毕业设计).doc 将本文的Word文档下载到电脑,方便复制、编辑、收藏和打印
本文链接:https://www.diyifanwen.net/c1i0ks3705c8az813jgo32teb88j4i5005rd_10.html(转载请注明文章来源)
热门推荐
Copyright © 2012-2023 第一范文网 版权所有 免责声明 | 联系我们
声明 :本网站尊重并保护知识产权,根据《信息网络传播权保护条例》,如果我们转载的作品侵犯了您的权利,请在一个月内通知我们,我们会及时删除。
客服QQ:xxxxxx 邮箱:xxxxxx@qq.com
渝ICP备2023013149号
Top