毕业生基本信息维护系统:
实现功能:对毕业生基本信息进行维护。
该查询界面的数据环境为:毕业生基本信息表
Label1的属性如下: Alignment=2-中央
BackColor=128,255,255
Caption=毕业生基本信息查询 FontBold=.T. FontName=楷体 FontSize=40
Forecolor=0,0,160 Height=72 Left=0 Top=0 Width=840
“添加”按钮的代码如下:
go bottom append blank thisform.refresh
“修改”按钮的代码如下:
a=messagebox(\确定要修改吗?\提示\
if a=1
sele 毕业生基本信息表
replace 毕业生基本信息表.学号 with
thisform.text1.value
replace 毕业生基本信息表.姓名 with thisform.text2.value
replace 毕业生基本信息表.性别 with thisform.text3.value
replace 毕业生基本信息表.出生年月 with thisform.text4.value
replace 毕业生基本信息表.政治面貌 with thisform.text5.value
replace 毕业生基本信息表.家庭住址 with thisform.text6.value
replace 毕业生基本信息表.民族 with thisform.text7.value
replace 毕业生基本信息表.学工号 with thisform.text8.value
replace 毕业生基本信息表.学历 with thisform.text9.value
replace 毕业生基本信息表.语种 with thisform.text10.value
replace 毕业生基本信息表.邮政编码 with thisform.text11.value
replace 毕业生基本信息表.手机号码 with thisform.text12.value
replace 毕业生基本信息表.Qq号码
with thisform.text13.value
replace 毕业生基本信息表.毕业院校 with thisform.text14.value
replace 毕业生基本信息表.所学专业 with thisform.text15.value messagebox(\修改成功!!!!\提示\ endif thisform.refresh
“删除“按钮的代码如下:
=messagebox(\确定要删除吗???\提示\delete pack skip-1
thisform.refresh
“退出”按钮的代码如下: Release Thisform
7.毕业生成绩信息表单
实现功能:查询成绩信息。
学生成绩查询表单属性: Auto Center:.F.--假
Caption:学生成绩查询表单 Font Name:宋体
Font size:9 Height:443
Picture: (自定义)Show window:2--作为顶层
Title bar:0--关闭 Top:0
clear
if thisform.optiongroup1.option1.value=1 then
Width:631
Window state:0--普通 按钮属性: Button count:2(其他属性可根据需要自行设定)
表单控件代码如下: 对象:command1 过程:click
xuehao=\ \sele 学生成绩及表现
xuehao=allt(thisform.txt学号.value)
*set filter to
locate all for 学生成绩及表现.学号=xuehao if not found() *set filter to 学生成绩及表现.学号=allt(thisform.txt学号.value)
*else =messagebox(\查无此人!\错误\
endif else
xm=\ \sele 学生成绩及表现
xm=allt(thisform.txt姓名.value)
*set filter to
a=messagebox(\确定修改吗?\提示\ if a=1 sele 学生成绩及表现 repl 学生成绩及表现.学号 with thisform.txt学号2.value repl 学生成绩及表现.姓名 with thisform.txt姓名2.value repl 学生成绩及表现.政治面貌 with thisform.txt政治面貌.value repl 学生成绩及表现.学业成绩 with thisform.txt学业成绩.value repl 学生成绩及表现.工作单位 with thisform.txt工作单位.value repl 学生成绩及表现.毕业去向 with thisform.txt毕业去向.value repl 学生成绩及表现.学校评价 with thisform.txt学校评价.value repl 学生成绩及表现.工资待遇 with thisform.txt工资待遇.value messagebox(\修改成功!\ endif thisform.refresh
Command6的Click事件的代码如下:xuehao=thisform.txt学号2.value use 学生成绩及表现 exclusive
if messagebox(\你真的要删除记录吗?\删除提示\
locate for 学生成绩及表现.姓名=xm if not found() *set filter to 学生成绩及表现.学号=allt(thisform.txt学号.value)
*else =messagebox(\查无此人!\错误\
endif endif
thisform.refresh
Command2的Click 事件代码如下: clear
release thisform
Command5的Click事件的代码如下: delete from 学生成绩及表现 where 学号=xuehao
pack
messagebox(\删除成功\提示\else
thisform.refresh endif
thisform.refresh
Command7的Click事件的代码如下: do form 学生成绩添加表单 thisform.release
Option 1的Click事件的代码如下: if this.value=1 then
thisform.txt学号.enabled=.t. thisform.txt学号.setfocus thisform.txt姓名.enabled=.f. endif
Option 2的Click事件的代码如下: if this.value=1 then
thisform.txt姓名.enabled=.t. thisform.txt姓名.setfocus thisform.txt学号.enabled=.f. endif
Form1的Init事件的代码如下: thisform.top=80 thisform.left=300
学生成绩录入表单:
实现功能:录入学生成绩。
(表单本身的设置属性没有很大的差别!这里不再介绍,请参照前几个属性)
repl 学生成绩及表现.姓名 with Form 1
thisform.txt姓名.value Init
代码如下: repl 学生成绩及表现.政治面貌
with thisform.txt政治面貌.value thisform.top=80
repl 学生成绩及表现.学业成绩 thisform.left=300
with thisform.txt学业成绩.value Command1
repl 学生成绩及表现.工作单位 Click
代码如下: with thisform.txt工作单位.value
repl 学生成绩及表现.毕业去向 clear
if empty(thisform.txt学号.value) with thisform.txt毕业去向.value messagebox(\学号不能为空!\提示\ repl 学生成绩及表现.学校评价
with thisform.txt学校评价.value else
locate for alltrim(学生成绩及表现.学 repl 学生成绩及表现.工资待遇 号)==alltrim(thisform.txt学号.value) with val(thisform.txt工资待遇.value)
\ if found() messagebox(\ 添加成功!
a=messagebox(\该记录已存在! thisform.release \提示\ endif
else endif sele 学生成绩及表现 Command 2 的 Click 事件的代码如下: appe blan repl 学生成绩及表现.学号 with thisform.txt学号.value
release thisform clear
8.毕业生学籍信息表单
老师对学生的学籍查询:
实现功能:查询学生学籍。
“查询”的click事件代码: '\ if do form 老师查询结果浏thisform.optiongroup1.option1.value=1 览.scx then else locate for alltrim(毕业生学籍. =messagebox(\输入的班级学号)==alltrim(thisform.combo1.value) 不存在,请重新输入!!!\提示\ if found () thisform.text1.value=\ b=recno() thisform.text1.setfocus do form 学生查询结果浏 endif 览.scx endif endif “退出”的click事件代码: else Release thisform thisform.optiongroup1.option2.value=1 Form1的init事件的代码: then locate for alltrim(毕业生学thisform.text1.enabled=.f. 籍.班级)==alltrim(thisform.text1.value) public c if !eof() public b c=\* from 毕业生thisform.top=80 学籍 where 班级 = thisform.left=300
按学号查询的结果浏览:
实现功能:显示查询的结果。