收藏 分销(赏)

vfp做的企业人事管理系统.docx

上传人:可**** 文档编号:4315649 上传时间:2024-09-05 格式:DOCX 页数:10 大小:727.85KB
下载 相关 举报
vfp做的企业人事管理系统.docx_第1页
第1页 / 共10页
vfp做的企业人事管理系统.docx_第2页
第2页 / 共10页
点击查看更多>>
资源描述
第一章 课程设计的题目 1.1 数据库技术与应用课程设计的题目 本次为期一周的课程设计的题目为设计一个企业人事管理系统。 第二章 课程设计的要求及目的 2.1 数据库技术与应用课程设计的要求及目的 课程设计的要求 1.符合课题要求,实现相应功能。可以加以其他功能或修饰,使程序更加完善、合理; 2.要求界面友好美观,操作方便易行; 3.注意程序的实用性、安全性; 4.随时记录设计情况(备查,也为编写设计说明书作好准备); 课程设计的目的 本课程设计其目的在于加深对《数据库技术与应用》的原理和程序的理解、巩固、提高,让学生做到学以致用,把所学的理论知识应用于实际问题的解决、编制出完整的应用程序,为以后的实际编制大型的应用软件打下基础。 第三章 课程设计的说明介绍 3.1 数据库技术与应用课程设计的说明介绍 先建立职工基本信息表、职工考核信息表,在数据库中建立关联,以便后面建立表单使用。 进入界面 “进入”代码如下: do case case thisform.optiongroup1.value=1 do form 管理员登陆界面 case thisform.optiongroup1.value=2 do form 一般用户登陆界面 endcase “退出”代码如下: quit 登录界面 “确定”代码如下: *设置密码不能为空,如允许为空则不需此步骤 If Len(Alltrim(Thisform.text2.Value))=0 Messagebox('请输入用户名或密码!') Return Endif Use gly.dbf Locate For Alltrim(用户名)==Alltrim(Thisform.text1.Value) *如果没有找到相同记录时执行下面代码 If Eof() Use Messagebox('没有此用户!') Thisform.text1.Value='' Thisform.text2.Value='' i=i+1 if i<=3 messagebox("密码或用户名错,请重新输入!") thisform.text2.value="" else Messagebox('连续三次输入错误,系统将退出!') Use Quit Endif Return ENDIF *找到后执行的动做 If Alltrim(Thisform.text2.Value)==Alltrim(密码) Mesagebox("可以进入!",4+8,"信息窗口") do form 管理界面 *在这里添加在正确登录后你要继续执行的程度 Else Use Messagebox('密码错误!') Thisform.text2.Value='' i=i+1 if i<=3 messagebox("密码错,请重新输入!") thisform.text2.value="" else Messagebox('连续三次输入错误,系统将退出!') Use Quit Endif Return ENDIF “取消”代码如下: thisform.text1.value="" thisform.text2.value="" “退出”代码如下: do form 进入界面 管理员功能界面 .1 添加信息界面 “添加”代码如下: use 职工信息表 append blank thisform.txt职工号.readonly=.f. thisform.txt姓名.readonly=.f. thisform.txt性别.readonly=.f. thisform.txt学历.readonly=.f. thisform.txt籍贯.readonly=.f. thisform.txt出生日期.readonly=.f. thisform.txt政治面貌.readonly=.f. thisform.txt所属部门.readonly=.f. thisform.txt进公司年份.readonly=.f. thisform.txt婚姻状况.readonly=.f. thisform.edt简历2.readonly=.f. “保存”代码如下: m=messagebox("是否保存?",4+48,"信息窗口") if m=6 messagebox("信息已保存",48,"信息窗口") else delete pack endif thisform.txt职工号.readonly=.t. thisform.txt姓名.readonly=.t. thisform.txt性别.readonly=.t. thisform.txt学历.readonly=.t. thisform.txt籍贯.readonly=.t. thisform.txt出生日期.readonly=.t. thisform.txt政治面貌.readonly=.t. thisform.txt所属部门.readonly=.t. thisform.txt进公司年份.readonly=.t. thisform.txt婚姻状况.readonly=.t. thisform.edt简历2.readonly=.t. “退出”代码如下: t .2 修改信息 可进行修改并保存,同时通过查找所要修改的记录,方便管理员修改。 “修改”代码如下: use 职工信息表 thisform.txt职工号.readonly=.f. thisform.txt姓名.readonly=.f. thisform.txt性别.readonly=.f. thisform.txt学历.readonly=.f. thisform.txt籍贯.readonly=.f. thisform.txt出生日期.readonly=.f. thisform.txt政治面貌.readonly=.f. thisform.txt所属部门.readonly=.f. thisform.txt进公司年份.readonly=.f. thisform.txt婚姻状况.readonly=.f. thisform.edt简历2.readonly=.f. “保存”代码如下: m=messagebox("是否保存?",4+48,"信息窗口") if m=6 messagebox("信息已保存",48,"信息窗口") thisform.txt职工号.readonly=.t. thisform.txt姓名.readonly=.t. thisform.txt性别.readonly=.t. thisform.txt学历.readonly=.t. thisform.txt籍贯.readonly=.t. thisform.txt出生日期.readonly=.t. thisform.txt政治面貌.readonly=.t. thisform.txt所属部门.readonly=.t. thisform.txt进公司年份.readonly=.t. thisform.txt婚姻状况.readonly=.t. thisform.edt简历2.readonly=.t. else endif “查找“代码如下: set order to 职工号 seek allt(thisform.text1.value) if !found() messagebox("此职工号不存在",48,"错误") go top endif thisform.text1.value="" .3删除界面 “删除”代码如下: m = messagebox("是否删除?",4+32,"信息窗口") if m=6 messagebox("记录已经删除!",48,"信息窗口") delete pack select 职工信息表 go bottom else endif .4查询界面 “查询”代码如下: getid=allt(thisform.text1.value) getname=allt(thisform.text2.value) getdepart=allt(thisform.text3.value) if flag1=0 and flag2=0 and flag3=0 messagebox("请输入查询条件",48,"错误") endif if flag1=1 and flag2=0 and flag3=0 select * from 职工信息表 where 职工号=getid into cursor aa thisform.grid1.recordsource="aa" endif if flag1=0 and flag2=1 and flag3=0 select * from 职工信息表 where 姓名=getname into cursor aa thisform.grid1.recordsource="aa" endif if flag1=0 and flag2=0 and flag3=1 select * from 职工信息表 where 所属部门=getdepart into cursor aa thisform.grid1.recordsource="aa" endif if flag1=1 and flag2=1 and flag3=0 select * from 职工信息表 where 职工号=gettid and 姓名=getname into cursor aa thisform.grid1.recordsource="aa" endif if flag1=0 and flag2=1 and flag3=1 select * from 职工信息表 where 姓名=getname and 所属部门=getdepart into cursor aa thisform.grid1.recordsource="aa" endif if flag1=1 and flag2=0 and flag3=1 select * from 职工信息表 where 职工号=getid and 所属部门=getdepart into cursor aa thisform.grid1.recordsource="aa" endif if flag1=1 and flag2=1 and flag3=1 select * from 职工信息表 where 职工号=getid and 姓名=getname and 所属部门=getdepart into cursor aa thisform.grid1.recordsource="aa" endif “清除”代码如下: thisform.check1.value=0 thisform.check2.value=0 thisform.check3.value=0 thisform.text1.value="" thisform.text2.value="" thisform.text3.value="" thisform.grid1.recordsource="" .5统计界面 “统计”代码如下: do case case thisform.optiongroup1.value=1 select 性别,count(*) as 人数 from 职工信息表 group by 性别 into cursor xx thisform.grid1.recordsource="xx" case thisform.optiongroup1.value=2 select 所属部门,count(*) as 人数 from 职工信息表 group by 所属部门 into cursor yy thisform.grid1.recordsource="yy" case thisform.optiongroup1.value=3 select 学历,count(*) as 人数 from 职工信息表 group by 学历 into cursor zz thisform.grid1.recordsource="zz" case thisform.optiongroup1.value=4 select 政治面貌,count(*) as 人数 from 职工信息表 group by 政治面貌 into cursor hh thisform.grid1.recordsource="hh" endcase “打印预览”代码如下: do case case thisform.G2.value=1 report form 职工信息报表 preview case thisform.G2.value=2 report form 职工考核信息报表 preview endcase “打印”代码如下: do case case thisform.G2.value=1 report form 职工信息报表 to printer prompt case thisform.G2.value=2 report form 职工考核信息报表 to printer prompt endcase 用户浏览界面 “第一个”代码如下: go top “上一个”代码如下: if.not.bof() skip -1 else messagebox("已经是第一个了!") endif “下一个”代码如下: if.not.eof() skip 1 else messagebox("已经是最后一个了!") endif “末一个”代码如下: go bottom “退出”代码如下:
展开阅读全文

开通  VIP会员、SVIP会员  优惠大
下载10份以上建议开通VIP会员
下载20份以上建议开通SVIP会员


开通VIP      成为共赢上传
相似文档                                   自信AI助手自信AI助手

当前位置:首页 > 包罗万象 > 大杂烩

移动网页_全站_页脚广告1

关于我们      便捷服务       自信AI       AI导航        抽奖活动

©2010-2025 宁波自信网络信息技术有限公司  版权所有

客服电话:4009-655-100  投诉/维权电话:18658249818

gongan.png浙公网安备33021202000488号   

icp.png浙ICP备2021020529号-1  |  浙B2-20240490  

关注我们 :微信公众号    抖音    微博    LOFTER 

客服