人事管理系统大数据库源代码

合集下载

【人事】人事工资管理系统源代码java

【人事】人事工资管理系统源代码java

【关键字】人事bm.javaimport java.awt.*;import ;import java.sql.*;import javax.swing.*;class bm extends Frame implements ActionListener,ItemListener { private condb conx=null;private ResultSet rs=null;private String sql=null;private Label num=new Label("职工号");private Label jb=new Label("税收");private Label fj=new Label("医疗保障");private Label in=new Label("退休保障");private TextField numtx=new TextField();private TextField jbtx=new TextField();private TextField fjtx=new TextField();private TextField intx=new TextField();private Choice numcho=new Choice();private Button add=new Button("增加");private Button exit=new Button("退出");public bm(){ setTitle("扣除工资");setSize(400,300);setBackground(Color.LIGHT_GRAY);this.setLocationRelativeTo(this.getParent());this.setResizable(false);setLayout(null);num.setBounds(80,50,50,20);jb.setBounds(80,80,50,20);fj.setBounds(80,110,50,20);in.setBounds(80,140,50,20);numtx.setBounds(160,50,100,20);jbtx.setBounds(160,80,100,20);fjtx.setBounds(160,110,100,20);intx.setBounds(160,140,100,20);numcho.setBounds(160,170,100,20);add.setBounds(60,220,50,20);exit.setBounds(300,220,50,20);add(add);add(exit);add(num);add(jb);add(fj);add(in);add(numtx);add(jbtx);add(fjtx);add(intx);add(numcho);//lbadd.addActionListener(this);exit.addActionListener(this);numcho.addItemListener(this);initnumcho();setVisible(true);addWindowListener(new WindowAdapter(){ public void windowClosing(WindowEvent e){dispose();}});}public void itemStateChanged(ItemEvent i){ numtx.setText(numcho.getSelectedItem());}public void initnumcho(){ conx=new condb();sql="select * from 扣除工资";numcho.removeAll();try { rs=conx.getrs(conx.con,sql);while(rs.next()){numcho.add(rs.getString("职工号"));}conx.dbclose(conx.con,rs);conx=null;rs=null;}catch(Exception eo){}}public void actionPerformed(ActionEvent e){ conx=new condb();if(e.getActionCommand().equals("退出"))this.dispose();if(e.getActionCommand().equals("增加")){sql="select * from 扣除工资where 职工号='"+numtx.getText()+"'";try{ rs=conx.getrs(conx.con,sql);if(rs.next()){sql="insert into 扣除工资(职工号,税收,医疗保险,养老保险)"+"values('"+numtx.getText().trim()+"',"+jbtx.getText()+","+fjtx.getText()+",'"+intx.getText()+"')";try { ;conx.dbclose(conx.con,null);}catch(Exception ue){""+ue);}JOptionPane jop=new JOptionPane();jop.showMessageDialog(null," 扣除工资添加成功!","添加成功",-1);conx.dbclose(conx.con,rs);numtx.setText("");jbtx.setText("");fjtx.setText("");conx=null;rs=null;}else { JOptionPane jop=new JOptionPane();jop.showConfirmDialog(null,"添加失败!","警告!",-1);conx.dbclose(conx.con,rs);conx=null;rs=null;}} catch(SQLException et){""+et);}}}}/*else*/bmcx.javaimport java.awt.*;import ;import java.sql.*;import javax.swing.*;import ;class bmcx extends Frame implements ActionListener{ private condb conc=null;private ResultSet rs=null;private String sql=null;private Label chao=new Label("职工号:");private Label cname=new Label("姓名:");private Label csex=new Label("税收:");private Label cage=new Label("医疗保险:"); private Label cdep=new Label("退休保险: "); private TextField chaotx=new TextField(); private Label cnametx=new Label("");private Label csextx=new Label("");private Label cagetx=new Label("");private Label cdeptx=new Label("");private Button cx=new Button("查询");private Button tc=new Button("退出");public bmcx(){ setTitle("扣除工资查询");setSize(400,250);setBackground(Color.LIGHT_GRAY);this.setLocationRelativeTo(this.getParent()); this.setResizable(false);setLayout(null);chao.setBounds(80,50,50,20);cname.setBounds(80,80,50,20);csex.setBounds(80,110,50,20);cage.setBounds(80,140,50,20);cdep.setBounds(80,170,50,20);chaotx.setBounds(160,50,150,20); cnametx.setBounds(160,80,150,20);csextx.setBounds( 160,110,150,20);cagetx.setBounds(160,140,150,20);cdeptx.setBounds(140,170,150,20);cx.setBounds(60,205,50,20);tc.setBounds(300,205,50,20);add(chao);add(cname);add(cagetx);add(cage);add(csex);add(cdep);add(chaotx);add(cnametx);add(csextx);add(cdeptx);add(cx);add(tc);setVisible(true);cx.addActionListener(this);tc.addActionListener(this); addWindowListener(new WindowAdapter(){ public void windowClosing(WindowEvent e){dispose();}});}public void actionPerformed(ActionEvent e){ if(e.getActionCommand().equals("退出"))this.dispose();if(e.getActionCommand().equals("查询")){ conc=new condb();sql="select 姓名,税收,医疗保险,退休保险from 扣除工资,职工where 扣除工资.职工号=职工.职工号and 扣除工资.职工号='"+chaotx.getText()+"'";try { rs=conc.getrs(conc.con,sql);if(rs.next()){cnametx.setText(rs.getString("姓名"));csextx.setText(rs.getString("税收"));cagetx.setText(rs.getString("医疗保险"));cdeptx.setText(rs.getString("退休保险"));conc.dbclose(conc.con,rs);conc=null;rs=null;}else {JOptionPane jop=new JOptionPane();jop.showConfirmDialog(null,"该用户不存在!","警告",-1);}}catch(Exception ee){}}}}condb.javaimport java.sql.*;public class condb{ public Connection con;//在类头定义连接对象public condb()//在此构造方法中实现有关程序的加载,同时捕捉异常。

人力资源管理系统源代码

人力资源管理系统源代码

1)登陆窗体代码设计窗体代码主要实现了连接数据库的功能,这里用于连接用户信息表.其程序如下:Private Sub Form_Load()Dim i As IntegerIf App。

PrevInstance ThenMsgBox (”程序已经运行,不能再次装载。

"), vbExclamationUnload MeEnd If'本段代码用于判定本程序是否已经装载于内存中,以避免程序的多重启动i = 0Open App.Path + ”\user。

ini” For Input As #1Do While Not EOF(1)Input #1, user(i), pws(i),state(i), Emplo(i)If state(i)= ”A” ThenCombo1。

AddItem user(i)End Ifi = i + 1Loop Close #1Combo1.ListIndex = 1'在窗口装载阶段读取用户设置文件获取用户信息并装载于用户列表框中End Sub(2)“取消”按钮是退出登录界面,退出系统的.其代码如下:Private Sub CmdCancel_Click()Unload MeEndEnd Sub(3)“确定”按钮代码设计“确定”按钮代码主要实现了用户登陆时,用户名和密码的认证,当用户名或密码错误时,系统提示错误。

其程序如下:Private Sub cmdOK_Click()If txtPassword = pws(Combo1.ListIndex)ThenCurId = Combo1.ListIndexEmploID = Emplo(CurId)CurUser = user(CurId)CurPsw = pws(CurId)Me.Hide’Load FrmMainFrmMain。

ShowElse MsgBox ”Invalid Password, try again!", , ”Login”txtPassword.SetFocusSendKeys "{Home}+{End}"End If End Sub(1)窗体选择的单击事件代码设计窗体选择的单击事件代码主要实现了进入本系统所有模块的功能,这里有以下几个模块,它们分别是员工信息模块,假条信息模块,工资管理模块,用户设置模块等/其程序如下:Private Sub Toolbar2_ButtonClick(ByVal Button As MSComctlLib.Button)Select Case Button。

人事管理系统数据库设计--sql代码

人事管理系统数据库设计--sql代码

建立数据库:create database 数据库建表:create table 部门信息表(部门编号char(2)primary key ,部门名称nchar(14),部门职能nchar(14),部门人数char (4))gocreate table 管理员信息表(用户名nchar(4)primary key ,密码char(10) ,)gocreate table 用户信息表(用户名char(10) primary key ,用户类型char(10),密码char(10))gocreate table 员工工作岗位表(姓名nchar(4)primary key ,员工编号char(4)工作岗位nchar(3) ,部门名称nchar(10),参加工作时间char (4))gocreate table 员工学历信息表(姓名nchar(4) primary key ,员工编号char(4)学历nchar(2),毕业时间char(10),毕业院校nchar (10),外语情况nchar(10),专业nchar(10))gocreate table 员工婚姻情况表(姓名nchar(4) primary key ,员工编号char(4)婚姻情况nchar(2) ,配偶姓名nchar(4),配偶年龄char (3),工作单位nchar(10),)gocreate table 员工基本信息表(员工编号char(4)primary key ,姓名nchar(4),性别nchar(1),民族nchar (3),出生年月char(14),学历nchar(10),政治面貌nchar(3),婚姻状况nchar(2),部门名称nchar(10),工作岗位nchar(10),)建立视图:CREATE VIEW 按员工工作岗位查询asSELECT 员工工作岗位表。

工作岗位, 员工基本信息表。

员工编号,员工基本信息表。

姓名, 员工基本信息表.性别, 员工基本信息表。

数据库人事管理系统代码

数据库人事管理系统代码
foreign key (manager_no) references worker_info(Worker_no)
on update cascade,
);
create table degree_info (
Degree_no varchar(15) primary key,
);
--创建插入员工存储过程
create procedure insertworker
@Worker_no varchar(15) ,--工号
@Worker_name varchar(8) ,--姓名
@Sex varchar(2) ,--性别
--插入学历信息
insert into degree_info(Degree_no,Worker_no,Degree,Major,School,Gradute_date)
values (@Degree_no,@Worker_no,@Degree,@Major,@School,@Gradute_date)
Worker_no varchar(15) ,
Degree varchar(4) ,
Major varchar(25) ,
School varchar(25) ,
Gradute_date date ,
foreign key (Worker_no) references worker_info(Worker_no) on update cascade on delete cascade
--插入部门存储过程
create procedure add_department
@Department_no varchar(15) ,

公司人事管理系统代码和文档

公司人事管理系统代码和文档

公司人事管理系统代码和文档公司人事管理系统专业软件工程移动应用开发学生姓名郭迁迁班级学号指导教师完成日期2014/6/20 1、功能图1、创建系统2、显示所有员工信息3、添加员工信息4、删除员工信息5、查找员工信息6、修改员工信息7、对员工月薪进行排序8、数据存盘0、退出系统输入账号密码进入系统公司人事管理系统2、类图技术经理类业务经理类文秘类技术人员类财务人员类经理类Person 类(基类) 3、界面不同用户进入的选择界面老板进入的界面员工进入的界面 4、数据存储结构写入文件退出系统进行相应的操作读取文件信息保存方式采用二进制进行数据的保存结构在每对员工的数据信息进行操作时,首先读取文件,然后进行下面增删查改等相应的操作,在对相应操作后自动进行数据的存盘读取方式读取链表,写入文件。

5、总结和体会通过这一次 C 课程设计,让我学到了很多,让我学到对一个大型系统的设计不止是对代码的实现,要有一个洞察全局的心,就是先想好,有一个大致的规划,然后再去用代码实现非常容易,如果不想好就会写代码,那么会遇到很多问题,有时会使所做的功夫白费,所以提前想好是非常重要的。

在写公司人事管理系统时我遇到了很多问题,例如对文件的添加,使自己没有一点办法,在老师的耐心讲解下,终于完成了文件的添加,使自己对于文件有了新的认识,老师为我们讲解了类的实现,使自己有了新的理解,还让我体会到了交流的重要性,我虽然是社团的人员,但是很少和别人交流。

我要学会去和别人交流想法。

代码如下include include using namespace std; void Link; class Person { protected char name[10];// 姓名 char level[20];// 级别 int NO;// 编号 int Flag;// 标记 public Person *next; Personchar na[10],char le[20],int no,int F; Person{} Person{} virtual void Show{} virtual double Wage{} int Get_NO; char *Get_Name; char *Get_Level; int Get_Flag; int *Get_Flag1; };PersonPersonchar na[10],char le[20],int no,int F { strcpyname,na; strcpylevel,le; NOno; FlagF; } intPersonGet_NO { return NO; } char *PersonGet_Name { return name; } char *PersonGet_Level { return level; } intPersonGet_Flag { return Flag; } int *PersonGet_Flag1 { return } class Managerpublic Person// 经理 manager. { public Managerchar na[10],char le[20],int no,int FPersonna,le,no,F{} Manager{} double Wage; void Show; }; double ManagerWage { return 5000; } void ManagerShow { cout n ; noi;// 编号ifn1 { strcpyle, 经理““ ;cout na; F1; p1new Managerna,le,no,F; }else ifn2 { strcpyle,技术“人员“ ;cout na;cout dm ;F2;p1new Technical na,le,dm,no,F; }else ifn3{strcpyle,业务“人员“; cout na;cout y;cout x;F3;p1new Businessna,le,y,x,no,F; }else ifn4{ strcpyle,业“务经理“ ;cout na;cout y;cout x;F4;p1new Business_Managerna,le,y,x,no,F; }else ifn5{strcpyle,文秘““; cout na; F5; p1new Secretaryna,le,no,F; } p2-nextp1; p2p1; i;cout ch; }whilech y ||ch Y ; p2-nextNULL; } void BossShow//显示本月员工的信息{Person *phead-next;ifpNULL{cout Show; pp-next; } } void BossAdd_Information//增添员工信息{ char na[10];char le[20]; int dm;double y;double x;int no;char ch; int F;do{ Person*phead,*p1;whilep-nextNULL{ pp-next; } int n; cout n; switchn {case 1strcpyle , “经理“ ;cout na; cout no; F1; p1new Managerna,le,no,F;break;case2strcpyle, 技术“人员“ ; cout na;cout dm;cout no;F2;p1new Technical na,le,dm,no,F;break; case 3strcpyle,业务人员““; cout na; cout y; cout x; cout no; F3; p1new Businessna,le,y,x,no,F;break; case 4strcpyle, 业“务经理“ ; coutna;cout y;cout x; cout no; F4;p1new Business_Managerna,le,y,x,no,F;break; case 5strcpyle,文秘““;cout na;cout no;F5; p1new Secretaryna,le,no,F;break; defaultcout nextp1;p1-nextNULL;cout ch ; }whilech y ||chY; }void BossDelete_Information//删除指定员工信息{ Person *p1,*p2; int num; char na[10]; int n; char ch; do { intflag0; cout n; ifn1 { cout num; p1head; whilep1-nextNULL { p2p1; p1p1-next; ifp1-Get_NOnum{ p2-nextp1-next; flag1; p1 NULL; delete p1; break; } } } else ifn2 { cout na; p1head; whilep1-nextNULL{p2p1;p1p1-next; ifstrcmpp1-Get_Name,na0 { p2-nextp1-next; p1NULL; delete p1; flag1; break; } } } else { cout删除成功删除失败 ,可能未存入此员工信息or 指令错误,请你核实后继续ch ; }whilech y||ch Y ;BossShow;// 调用函数显示结果}void BossSearch_Information// 查找信息{char ch;do{Person *p1head-next;int S_num;cout S_num;whilep1NULL { ifp1-Get_NOS_num { cout Show; break; } p1p1-next; } coutch; }whilech Y ||ch y ; } void BossStaff//员工功能 { cout next;ifp1NULL{cout name;whilep1NULL {ifstrcmpp1-Get_Name,name0{cout S_num; ifp1-Get_NOS_num { cout Show; cout n; ifn0 { exit-1;}} else {cout next; }} void BossModify_Information//修改指定员工的信息{Person *p1head-next,*p2head,*p3NULL;char na[10]; char le[20]; int dm; double y; double x; int no; int num;int F;cout num;int i0;whilep1NULL { ifp1-Get_NOnum { int n; cout Show;cout n; switchn{case 1strcpyle,经理““ ;cout na; cout no; F1; p3new Managerna,le,no,F;break; case2strcpyle, 技术“人员“ ; cout n a; cout dm ; cout no; F2;p3new Technical na,le,dm,no,F;break; case 3strcpyle, 业务人员““; cout na; cout y; cout x; cout no; F3; p3new Businessna,le,y,x,no,F;break; case 4strcpyle, 业务“经理“ ;coutna;cout y;cout x;cout no; F4;p3new Business_Managerna,le,y,x,no,F;break;case 5strcpyle,文秘““;cout na;cout no;F5; p3new Secretaryna,le,no,F;break; defaultcout nextp1-next; p2-nextp3; delete p1; i1; } p1p1-next;p2p2-next; } ifi0 { cout nextNULL { min1phead; minqhead-next; whileqNULL { ifq-Wage min-Wage { min1p; minq; } qq-next;pp-next; } min1-nextmin-next;min-nextNULL; h-nextmin; hmin;}headnewhead; cout next;ofstream myfile“员工管理 .txt“; ofstream my“郭迁迁 .txt“; ifmyfile||my{ coutGet_Flag; switchn { case 1sizesizeofManager;break; case2sizesizeofTechnical ;break; case 3sizesizeofBusiness;break;case4sizesizeofBusiness_Manager;break;case5sizesizeofSecretary;break;}my.writechar*p-Get_Flag1,sizeofint;myfile.writechar*p,size;pp-next;}whilepNULL;myfile.close; my.close; }void BossRead_File { Person *p1,*p2; char na[10];char jb[20];intdm; double y; double x; int no; int num; int F; ifstream infile员工管理 .txt“ifstream;in “郭迁迁 .txt“ifinfile||in;{ cout 0 { p1-nextp2; p1p2; } int n; in.readchar * switchn { case1sizesizeofManagerna,jb,no,F; p2new Managerna,jb,no,F;break;case 2sizesizeofTechnical na,jb,dm,no,F; p2new Technicalna,jb,dm,no,F;break; case 3sizesizeofBusinessna,jb,y,x,no,F;p2newBusinessna,jb,y,x,no,F;break;case4sizesizeofBusiness_Managerna,jb,y,x,no,F;p2newBusiness_Managerna,jb,y,x,no,F;break;case5sizesizeofSecretaryna,jb,no,F; p2new Secretaryna,jb,no,F;break; } i; }whileinfile.readchar *p2,size;p2-nextNULL;in.close;infile.close;}bool Account// 帐号{ char z[7];ifstream ifile“ Account.txt“ ifi,iosout;le.getlinez,7;ifile.close;int flag1;whileflag {char zh[7];cout m;ifstrcmpmm,m0{ return true; break;}else{flag;ifflag2 { return false; } } } } void Instructions { char arry[1000];ifstream ifile使“ 用说明.txt“ ,iosout;ifile.getlinearry,1000;ifile. close; cout endl; cout“\t\t\t欢迎大家阅读使用说明“ endl endl; cout arry endl; } void Link { Boss b; int n;int m0; while1 { cout“ t****************“endl; cout。

人事管理系统数据库源代码

人事管理系统数据库源代码

人事管理系统数据库源代码using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;namespace WebApplication1{public partial class WebForm1 : System.Web.UI.Page {protected void Page_Load(object sender, EventArgs e) {}protected void Button1_Click(object sender, EventArgs e) {Response.Redirect("~/登录.aspx");}protected void Button2_Click(object sender, EventArgs e) {Response.Redirect("~/人员信息查询.aspx");}protected void Button3_Click(object sender, EventArgs e){Response.Redirect("~/人员修改.aspx");}protected void Button4_Click(object sender, EventArgs e) {Response.Redirect("~/部门信息.aspx");}protected void Button5_Click(object sender, EventArgs e) {Response.Redirect("~/工资信息.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class部门信息: System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){bool find =false;SqlConnection con=new SqlConnection("server=localhost;IntegratedSecurity=SSPI;database=人事管理系统");con.Open();string cmdstr="select * from 部门表";SqlDataAdapter da=new SqlDataAdapter(cmdstr,con);DataSet ds=new DataSet();da.Fill(ds);for(int i=0;i<ds.tables[0].rows.count;i++)< p="">{for(int j=0;j<ds.tables[0].columns.count;j++)< p="">{String data=(ds.Tables[0].Rows[i][j].T oString()).Trim();if(data==TextBox1.Text.Trim()){TextBox2.Text=ds.T ables[0] .Rows[i]["部门代码"].T oString();TextBox3.Text=ds.T ables[0] .Rows[i]["部门名称"].T oString();find=true;}}}if (find == false){Response.Write("");con.Close();}}protected void Button2_Click(object sender, EventArgs e) {Response.Redirect("~/Default.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;using System.Data.SqlTypes;namespace WebApplication1{public partial class_Default : System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e) {}protected void TextBox1_TextChanged(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){SqlConnection con = new SqlConnection("server=localhost;IntegratedSecurity=SSPI;database=人事管理系统");string strCount;strCount = "select * from 人事表"; con.Open();SqlCommand= new SqlCommand(strCount, con);SqlDataReader dr = .ExecuteReader();string strUsername = "", strPassword = "";while (dr.Read()){if (TextBox1.Text == dr["编号"].ToString()||TextBox2.Text == dr["用户密码"].ToString()){strUsername = dr["编号"].T oString();strPassword = dr["用户密码"].T oString();break;}}dr.Close();con.Close();if (strUsername == ""){Response.Write("");return;}protected void Button2_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class工资信息: System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void TextBox2_TextChanged(object sender, EventArgs e)}protected void TextBox5_TextChanged(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){bool find = false;SqlConnection con = new SqlConnection("server=localhost;IntegratedSecurity=SSPI;database=人事管理系统");con.Open();string cmdstr = "select * from 工资表";SqlDataAdapter da = new SqlDataAdapter(cmdstr, con);DataSet ds = new DataSet();da.Fill(ds);for (int i = 0; i < ds.Tables[0].Rows.Count; i++){for (int j = 0; j < ds.Tables[0].Columns.Count; j++){String data = (ds.T ables[0].Rows[i][j].ToString()).Trim();if (data == TextBox1.Text.Trim()){TextBox2.Text = ds.Tables[0].Rows[i]["应发工资"].T oString();TextBox3.Text = ds.Tables[0].Rows[i]["岗位津贴"].T oString();TextBox4.Text = ds.Tables[0].Rows[i]["奖励"].T oString();TextBox5.Text = ds.Tables[0].Rows[i]["保险"].T oString();find = true;}}if (find == false){Response.Write("");con.Close();}}protected void Button2_Click(object sender, EventArgs e) {Response.Redirect("~/Default.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class人员信息: System.Web.UI.Pageprotected void Page_Load(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}protected void Button2_Click(object sender, EventArgs e){bool find =false;SqlConnection con = new SqlConnection("server=localhost;IntegratedSecurity=SSPI;database=人事管理系统");con.Open();string cmdstr="select * from 工资表";SqlDataAdapter da=new SqlDataAdapter(cmdstr,con);DataSet ds=new DataSet();da.Fill(ds);for(int i=0;i<ds.tables[0].rows.count;i++)< p="">{for(int j=0;j<ds.tables[0].columns.count;j++)< p="">{String data=(ds.Tables[0].Rows[i][j].T oString()).Trim();if(data==TextBox1.Text.Trim()){TextBox2.Text=ds.T ables[0] .Rows[i]["应发工资"].T oString();TextBox3.Text=ds.T ables[0] .Rows[i]["岗位津贴"].T oString();TextBox4.Text=ds.T ables[0] .Rows[i]["奖励"].T oString();TextBox5.Text = ds.Tables[0].Rows[i]["保险"].T oString();find=true;}}}if (find == false){Response.Write("");con.Close();}}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class人员修改: System.Web.UI.Page {protected void Page_Load(object sender, EventArgs e){}protected void TextBox5_TextChanged(object sender, EventArgs e){}protected void Button2_Click(object sender, EventArgs e){SqlConnection con=new SqlConnection("server=localhost;IntegratedSecurity=SSPI;database=人事管理系统");con.Open();string insert="insert into 人事表(员工号,姓名,性别,职称,学历) values("+""+ TextBox1.T ext.Trim() +""+","+"" + TextBox2.Text.Trim() +""+","+ TextBox3.Text.Trim() + "," +""+ TextBox4.Text.Trim() +""+","+"" +TextBox5.Text.Trim() + ""+")";Response.Write(insert);SqlCommand cmd1=new SqlCommand(insert,con);con.Close();}protected void Button1_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}protected void GridView1_SelectedIndexChanged(object sender, EventArgs e){}}}</ds.tables[0].columns.count;j++)<> </ds.tables[0].rows.count;i++)<></ds.tables[0].columns.count;j++)<> </ds.tables[0].rows.count;i++)<>。

人事管理系统毕业设计(设计与代码实现)

人事管理系统毕业设计(设计与代码实现)

摘要随着计算机技术的飞速发展,计算机在企业管理中应用的普及,利用计算机实现企业人事管理势在必行。

本系统结合公司实际的人事管理制度,经过实际的需求分析,采用功能强大的Visual Basic6.0作为开发工具而开发出来的单机版人事管理系统。

整个系统从符合操作简便、界面友好、灵活、实用、安全的要求出发,完成人事管理的全过程,包括新进员工加入时人事档案的建立、老员工的转出、职位等的变动引起职工信息的修改、员工信息查询、统计等人事管理工作以及新进员的新增、老员工修改等管理工作。

经过实际使用证明,本文所设计的人事管理系统可以满足公司人事管理方面的需要。

关键词:VB、数据库、窗体、测试、目录第一章概述 (4)1.1、本课题的来源 (4)1.2、本论文的目的、内容及作者主要贡献 (4)第二章开好发工具的选择 (4)第三章系统调研及可行性分析 (7)3.1、系统调研 (7)3.2、可靠性分析概述 (8)3.3、技术可行性分析 (8)第四章系统分析 (9)4.1、系统需求分析 (9)4.2、数据流程图 (10)第五章系统总体设计 (10)5.1、功能描述 (10)5.2、系统操作流程图 (11)第六章系统详细设计 (12)6.1、数据库设计 (12)6.2、系统主要界面 (13)第七章系统测试 (16)7.1、测试举例 (16)7.2、测试项目 (17)7.3、测试方法 (18)致谢 (19)参考文献 (20)附件:源程序…………………………………………………………………………21第一章概述1、本课题的来源随着计算机技术的飞速发展,计算机在企业管理中应用的普及,利用计算机实现企业人事管理势在必行。

对于大中型企业来说,利用计算机支持企业高效率完成劳动人事管理的日常事务,是适应现代企业制度要求、推动企业劳动人事管理走向科学化、规范化的必要条件;计算机管理所无法比拟的优点检索迅速、查找方便、可靠性高、存储量大、保密性好、寿命长、成本低等。

oracle课程设计人事管理系统(附源代码)

oracle课程设计人事管理系统(附源代码)
item43=new JMenuItem("修改岗位信息");
item44=new JMenuItem("查询岗位信息");
item45=new JMenuItem("删除岗位信息");
item42.addActionListener(this);
item43.addActionListener(this);
}
}
class WindowMenu extends JFrame implements ActionListener{
JMenuBar menubar;
JMenu menu1,menu2,menu3,menu4,menu5,menu6,menu7;
JMenuItem item11,item12,item13,item14;
JMenuItem item46,item47,item48,item49;
JMenuItem item41;
inputdata input;
selectdata select;
alterdata alter;
deletedata delete;
inputshortdata inputs;
selectshortdata selects;
altershortdata alters;
deleteshortdata deletes;
inputdepart inputp;
alterdepart alterp;
selectdepart selectp;
deletepart deletep;
inputworker inputw;
alterworker alterw;
item49.addActionListener(this);
  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;namespace WebApplication1{public partial class WebForm1 : System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e) {Response.Redirect("~/登录.aspx");}protected void Button2_Click(object sender, EventArgs e) {Response.Redirect("~/人员信息查询.aspx");}protected void Button3_Click(object sender, EventArgs e) {Response.Redirect("~/人员修改.aspx");}protected void Button4_Click(object sender, EventArgs e) {Response.Redirect("~/部门信息.aspx");}protected void Button5_Click(object sender, EventArgs e) {Response.Redirect("~/工资信息.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class部门信息 : System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){bool find =false;SqlConnection con=new SqlConnection("server=localhost;Integrated Security=SSPI;database=人事管理系统");con.Open();string cmdstr="select * from 部门表";SqlDataAdapter da=new SqlDataAdapter(cmdstr,con);DataSet ds=new DataSet();da.Fill(ds);for(int i=0;i<ds.Tables[0].Rows.Count;i++){for(int j=0;j<ds.Tables[0].Columns.Count;j++){String data=(ds.Tables[0].Rows[i][j].ToString()).Trim();if(data==TextBox1.Text.Trim()){TextBox2.Text=ds.Tables[0] .Rows[i]["部门代码"].ToString();TextBox3.Text=ds.Tables[0] .Rows[i]["部门名称"].ToString();find=true;}}}if (find == false){Response.Write("<script>window.alert('没有相关记录!')</script>");con.Close();}}protected void Button2_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;using System.Data.SqlTypes;namespace WebApplication1{public partial class_Default : System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void TextBox1_TextChanged(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){SqlConnection con = new SqlConnection("server=localhost;IntegratedSecurity=SSPI;database=人事管理系统");string strCount;strCount = "select * from 人事表"; con.Open();SqlCommand com = new SqlCommand(strCount, con);SqlDataReader dr = com.ExecuteReader();string strUsername = "", strPassword = "";while (dr.Read()){if (TextBox1.Text == dr["编号"].ToString()||TextBox2.Text == dr["用户密码"].ToString()){strUsername = dr["编号"].ToString();strPassword = dr["用户密码"].ToString();break;}}dr.Close();con.Close();if (strUsername == ""){Response.Write("<script language=javascript>alert('登录成功!');</script>");return;}}protected void Button2_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class工资信息 : System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void TextBox2_TextChanged(object sender, EventArgs e){}protected void TextBox5_TextChanged(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){bool find = false;SqlConnection con = new SqlConnection("server=localhost;Integrated Security=SSPI;database=人事管理系统");con.Open();string cmdstr = "select * from 工资表";SqlDataAdapter da = new SqlDataAdapter(cmdstr, con);DataSet ds = new DataSet();da.Fill(ds);for (int i = 0; i < ds.Tables[0].Rows.Count; i++){for (int j = 0; j < ds.Tables[0].Columns.Count; j++){String data = (ds.Tables[0].Rows[i][j].ToString()).Trim();if (data == TextBox1.Text.Trim()){TextBox2.Text = ds.Tables[0].Rows[i]["应发工资"].ToString(); TextBox3.Text = ds.Tables[0].Rows[i]["岗位津贴"].ToString(); TextBox4.Text = ds.Tables[0].Rows[i]["奖励"].ToString();TextBox5.Text = ds.Tables[0].Rows[i]["保险"].ToString();find = true;}}}if (find == false){Response.Write("<script>window.alert('没有相关记录!')</script>");con.Close();}}protected void Button2_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class人员信息 : System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void Button1_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}protected void Button2_Click(object sender, EventArgs e){bool find =false;SqlConnection con = new SqlConnection("server=localhost;Integrated Security=SSPI;database=人事管理系统");con.Open();string cmdstr="select * from 工资表";SqlDataAdapter da=new SqlDataAdapter(cmdstr,con);DataSet ds=new DataSet();da.Fill(ds);for(int i=0;i<ds.Tables[0].Rows.Count;i++){for(int j=0;j<ds.Tables[0].Columns.Count;j++){String data=(ds.Tables[0].Rows[i][j].ToString()).Trim();if(data==TextBox1.Text.Trim()){TextBox2.Text=ds.Tables[0] .Rows[i]["应发工资"].ToString();TextBox3.Text=ds.Tables[0] .Rows[i]["岗位津贴"].ToString();TextBox4.Text=ds.Tables[0] .Rows[i]["奖励"].ToString();TextBox5.Text = ds.Tables[0].Rows[i]["保险"].ToString();find=true;}}}if (find == false){Response.Write("<script>window.alert('没有相关记录!')</script>");con.Close();}}}}using System;using System.Collections;using System.Configuration;using System.Data;using System.Linq;using System.Web;using System.Web.Security;using System.Web.UI;using System.Web.UI.HtmlControls;using System.Web.UI.WebControls;using System.Web.UI.WebControls.WebParts;using System.Xml.Linq;using System.Data.SqlClient;namespace WebApplication1{public partial class人员修改 : System.Web.UI.Page{protected void Page_Load(object sender, EventArgs e){}protected void TextBox5_TextChanged(object sender, EventArgs e){}protected void Button2_Click(object sender, EventArgs e){SqlConnection con=new SqlConnection("server=localhost;IntegratedSecurity=SSPI;database=人事管理系统");con.Open();string insert="insert into 人事表(员工号,姓名,性别,职称,学历) values("+""+ TextBox1.Text.Trim() +""+","+"" + TextBox2.Text.Trim() +""+","+ TextBox3.Text.Trim() + "," +""+ TextBox4.Text.Trim() +""+","+"" +TextBox5.Text.Trim() + ""+")";Response.Write(insert);SqlCommand cmd1=new SqlCommand(insert,con);con.Close();}protected void Button1_Click(object sender, EventArgs e){Response.Redirect("~/Default.aspx");}protected void GridView1_SelectedIndexChanged(object sender, EventArgs e){} }}。

相关文档
最新文档