发廊小系统.docx
《发廊小系统.docx》由会员分享,可在线阅读,更多相关《发廊小系统.docx(15页珍藏版)》请在冰豆网上搜索。
![发廊小系统.docx](https://file1.bdocx.com/fileroot1/2023-1/2/e01bbffb-a01f-4395-86ae-fec412dadef4/e01bbffb-a01f-4395-86ae-fec412dadef41.gif)
发廊小系统
我做的vfp发廊管理信息系统&代码
登录系统
确定按钮代码
selectmmb
locateforalltrim(thisform.text1.value)=alltrim(用户名)
iffound()andalltrim(thisform.text2.value)=alltrim(密码)
thisform.release
doform主界面
else
i=i+1
ifi<3
messagebox("您输入有误,请重试!
",64,"错误")
thisform.text1.value=""
thisform.text2.value=""
thisform.text2.enabled=.f.
thisform.text1.enabled=.t.
thisform.text1.setfocus
else
messagebox("您输入有误,禁止进入系统!
",64,"错误")
thisform.release
endif
endif
取消按钮代码
mand1.enabled=.t.
thisform.text1.value=""
thisform.text2.value=""
thisform.label2.visible=.f.
thisform.text2.visible=.f.
mand1.enabled=.f.
mand2.enabled=.f.
thisform.image1.visible=.f.
thisform.text1.enabled=.t.
thisform.text1.setfocus
退出按钮代码
thisform.release
欢迎系统form代码
thisform.release
doform登录表单
timer代码
ifthisform.label1.left>=0
thisform.label1.left=thisform.label1.left-5
else
thisform.label1.left=thisform.width
endif
i=int(rand()*225
j=int(rand()*225
k=int(rand()*225
thisform.label1.forecolor=rgb(i,j,k)
计算工资代码
aa=val(thisform.text1.value)
bb=val(thisform.text2.value)
cc=val(thisform.text3.value)
thisform.text4.value=allt(str(aa+bb-cc))
thisform.refresh
退出按钮代码
thisform.release
利润计算按钮代码
aa=val(thisform.text1.value)
bb=val(thisform.text2.value)
cc=val(thisform.text3.value)
dd=val(thisform.text4.value)
thisform.text5.value=allt(str(aa-bb-cc-dd))
thisform.refresh
退出按钮代码
thisform.release
添加按钮代码
if!
empty(thisform.text1.value)and!
empty(thisform.text2.value)and!
empty(thisform.text3.value)and!
empty(thisform.text4.value)
selectguest
locateforalltrim(编号)==alltrim(thisform.text1.value)
iffound()
messagebox("此编号已存在!
",48,"信息窗口")
thisform.text1.vallue=""
thisform.text1.setfocus
else
yn=messagebox("确定添加么?
",4+32,"信息窗口")
ifyn=6
appendblank
gobottom
replace编号withalltrim(thisform.text1.value)
replace姓名withalltrim(thisform.text2.value)
replace性别withalltrim(thisform.text3.value)
replace级别withalltrim(thisform.text4.value)
messagebox("成功添加会员",48,"信息窗口")
thisform.text1.value=0
thisform.text2.value=""
thisform.text3.value=""
thisform.text4.value=""
thisform.text1.setfocus
thisform.refresh
else
thisform.text1.setfocus
endif
endif
else
messagebox("内容不能为空!
",48,"信息窗口")
endif
清空按钮代码
thisform.text1.value=0
thisform.text2.value=""
thisform.text3.value=""
thisform.text4.value=""
thisform.refresh
退出按钮代码
thisform.refresh
查询按钮代码
selectguest
ifempty(thisform.text1.value)
messagebox("请输入姓名",64,"信息提示")
else
docase
casethisform.optiongroup1.value=1
locateforalltrim(姓名)==alltrim(thisform.text1.value)
iffound()
select*fromgl!
guest
whereguest.姓名==alltrim(thisform.text1.value)intocursorjqcx
thisform.grid1.recordsource="jqcx"
thisform.grid1.refresh
else
messagebox("没有这个人",64,"信息提示")
endif
casethisform.optiongroup1.value=2
locateforalltrim(thisform.text1.value)$alltrim(姓名)
iffound
select*fromgl!
guest;
wherealltrim(thisform.text1.value)$alltrim(姓名)intocursormhcx
thisform.grid1.recordsource="mhcx"
thisform.grid1.refresh
else
messagebox("没有这个人",64,"信息提示")
endif
endcase
endif
退出按钮代码
thisform.release
添加按钮代码
if!
empty(thisform.text1.value)and!
empty(thisform.text2.value)and!
empty(thisform.text3.value)and!
empty(thisform.text4.value)and!
empty(thisform.text5.value)and!
empty(thisform.text6.value)and!
empty(thisform.text7.value)and!
empty(thisform.text8.value)and!
empty(thisform.text9.value)
selectworker
locateforalltrim(编号)==alltrim(thisform.text1.value)
iffound()
messagebox("此编号员工已存在!
",48,"信息窗口")
thisform.text1.value=""
thisform.text1.setfocus
else
yn=messagebox("确定添加么?
",4+32,"信息窗口")
ifyu=9
appendblank
gobottom
replace编号withthisform.text1.value
replace姓名withalltrim(thisform.text2.value)
replace性别withalltrim(thisform.text3.value)
replace生日withthisform.text4.value
replace民族withalltrim(thisform.text5.value)
replace学历withalltrim(thisform.text6.value)
replace电话withthisform.text7.value
replace级别withalltrim(thisform.text8.value)
replace地址withalltrim(thisform.text9.value)
messagebox("成功添加员工记录",48,"信息窗口")
thisform.text1.value=0
thisform.text2.value=""
thisform.text3.value=""
thisform.text4.value=0
thisform.text5.value=""
thisform.text6.value=""
thisform.text7.value=0
thisform.text8.value=""
thisform.text9.value=""
thisform.text1.setfocus
thisform.refresh
else
thisform.text1.setfocus
endif
endif
else
messagebox("内容不能为空",48,"信息窗口")
endif
清空按钮代码
thisform.text1.value=0
thisform.text2.value=""
thisform.text3.value=""
thisform.text4.value=0
thisform.text5.value=""
thisform.text6.value=""
thisform.text7.value=0
thisform.text8.value=""
thisform.text9.value=""
thisform.refresh
退出按钮代码
thisform.refresh
首记录按钮代码
gotop
mand2.enabled=.f.
mand3.enabled=.t.
thisform.refresh
上条记录按钮代码
ifbof()
messagebox("已是第一条记录",48,"信息窗口")
mand2.enabled=.f.
else
skip-1
mand3.enabled=.t.
endif
thisform.refresh
下条记录按钮代码
ifeof()
messagebox("已是最后一条记录",48,"信息窗口")
mand3.enabled=.f.
else
skip
mand2.enabled=.t.
endif
thisform.refresh
末记录按钮代码
gobottom
mand3.enabled=.f.
mand2.enabled=.t.
thisform.refresh
修改按钮代码
ifmand1.caption="修改"
mand1.caption="保存"
thisform.txt编号.enabled=.t.
thisform.txt姓名.enabled=.t.
thisform.txt性别.enabled=.t.
thisform.txt级别.enabled=.t.
mand1.enabled=.f.
mand2.enabled=.f.
mand3.enabled=.f.
mand4.enabled=.f.
else
yn=messagebox("确定保存么?
",4+32,"信息窗口")
ifyn=6
=tablerevert(.t.)
replace编号withthisform.txt编号.value
replace姓名withthisform.txt姓名.value
replace性别withthisform.txt性别.value
replace级别withthisform.txt级别.value
thisform.refresh
thisform.txt编号.enabled=.f.
thisform.txt姓名.enabled=.f.
thisform.txt性别.enabled=.f.
thisform.txt级别.enabled=.f.
mand1.caption="修改"
mand1.enabled=.t.
mand2.enabled=.t.
mand3.enabled=.t.
mand4.enabled=.t.
else
=tablerevert(.f.)
thisform.txt编号.enabled=.f.
thisform.txt姓名.enabled=.f.
thisform.txt性别.enabled=.f.
thisform.txt级别.enabled=.f.
mand1.caption="修改"
mand1.enabled=.t.
mand2.enabled=.t.
mand3.enabled=.t.
mand4.enabled=.t.
thisform.refresh
endif
endif