华北科技学院_Delphi实验报告_简易学生信息管理系统(6)

2021-01-20 18:32

华北科技学院_Delphi实验报告_简易学生信息管理系统

华北科技学院计算机学院综合性实验报告

end; end; 2: begin StrSql:='select * from info where ClassName='''+trim(EdtContent.text)+''''; if QryStu.Active then begin QryStu.Active:=false; QryStu.SQL.Clear; QryStu.SQL.Add(StrSql); QryStu.Active:=true; if QryStu.Bof and QryStu.Eof then begin MessageDlg('查无此人!,请重新输入班级',mtError,[mbOK],1); EdtContent.Text:=''; EdtContent.SetFocus; end; end; end; 3: begin StrSql:='select * from info where Sex='''+trim(EdtContent.text)+''''; if QryStu.Active then begin QryStu.Active:=false; QryStu.SQL.Clear; QryStu.SQL.Add(StrSql); QryStu.Active:=true; if QryStu.Bof and QryStu.Eof then begin MessageDlg('性别输入错误,请重新输入性别',mtError,[mbOK],1); EdtContent.Text:=''; EdtContent.SetFocus; end; end; end; end; end; end; 4) 、信息管理界面新增记录按钮 btnAdd 的 onClick 事件过程代码为: procedure TFrmStudent.BtnAddClick(Sender: TObject); begin if EdtNum.Text='' then begin MessageBox(0,'学号内容不能为空!','错误',MB_OK); EdtNum.SetFocus; end else QryStu.Close; QryStu.SQL.Clear; QryStu.SQL.Text:='select * from info where snum='''+EdtNum.Text+''''; QryStu.Open; if not(QryStu.Eof and QryStu.Bof) then begin MessageBox(0,'学号不能重复','错误',0); EdtNum.SetFocus; Exit; end else第 5 页


华北科技学院_Delphi实验报告_简易学生信息管理系统(6).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:焊接专业毕业论文

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: