⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 jcdyunit.pas

📁 高校学生学籍管理系统源码
💻 PAS
字号:
unit jcdyunit;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, ComCtrls,datadomule;

type
  Tjcdy = class(TForm)
    PageControl1: TPageControl;
    TabSheet1: TTabSheet;
    TabSheet2: TTabSheet;
    GroupBox1: TGroupBox;
    RadioButton1: TRadioButton;
    RadioButton2: TRadioButton;
    Edit1: TEdit;
    Button1: TButton;
    GroupBox2: TGroupBox;
    RadioButton3: TRadioButton;
    RadioButton4: TRadioButton;
    Edit2: TEdit;
    Button2: TButton;
    procedure RadioButton2Click(Sender: TObject);
    procedure RadioButton1Click(Sender: TObject);
    procedure Edit1Enter(Sender: TObject);
    procedure Button1Click(Sender: TObject);
    procedure RadioButton4Click(Sender: TObject);
    procedure RadioButton3Click(Sender: TObject);
    procedure Edit2Enter(Sender: TObject);
    procedure Button2Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  jcdy: Tjcdy;

implementation

uses jldyfrmunit, cfdyfrmunit;

{$R *.dfm}

procedure Tjcdy.RadioButton2Click(Sender: TObject);
begin
edit1.text:='请输入学号';
end;

procedure Tjcdy.RadioButton1Click(Sender: TObject);
begin
edit1.text:='请输入年份';
end;

procedure Tjcdy.Edit1Enter(Sender: TObject);
begin
edit1.Clear ;
end;

procedure Tjcdy.Button1Click(Sender: TObject);
begin
if radiobutton1.Checked then
begin
with datamodule1.qry_jcdy1 do
begin
close;
sql.Clear ;
sql.Add('select * from viewjlcx where sj00 like :id' );
parambyname('id').asstring:=edit1.text+'%';
open;
if not findfirst then
begin
application.MessageBox('没有检索到符合条件的信息','提示',mb_ok+mb_iconinformation);
exit;
end;
end;
end;

if radiobutton2.Checked then
begin
with datamodule1.qry_jcdy1 do
begin
close;
sql.Clear ;
sql.Add('select * from viewjlcx where xsxh_id=:id' );
parambyname('id').asstring:=edit1.text;
open;
if not findfirst then
begin
application.MessageBox('没有检索到符合条件的信息','提示',mb_ok+mb_iconinformation);
exit;
end;
end;
end;
jldyfrm:=tjldyfrm.create(self);
jldyfrm.showmodal;
end;

procedure Tjcdy.RadioButton4Click(Sender: TObject);
begin
edit2.text:='请输入学号';
end;

procedure Tjcdy.RadioButton3Click(Sender: TObject);
begin
edit2.text:='请输入年份';
end;

procedure Tjcdy.Edit2Enter(Sender: TObject);
begin
 edit2.Clear ;
end;

procedure Tjcdy.Button2Click(Sender: TObject);
begin
if radiobutton3.Checked then
begin
with datamodule1.qry_jcdy do
begin
close;
sql.Clear ;
sql.Add('select * from viewcfcx where sj00 like :id' );
parambyname('id').asstring:=edit2.text+'%';
open;
if not findfirst then
begin
application.MessageBox('没有检索到符合条件的信息','提示',mb_ok+mb_iconinformation);
exit;
end;
end;
end;

if radiobutton4.Checked then
begin
with datamodule1.qry_jcdy do
begin
close;
sql.Clear ;
sql.Add('select * from viewcfcx where xsxh_id=:id' );
parambyname('id').asstring:=edit2.text;
open;
if not findfirst then
begin
application.MessageBox('没有检索到符合条件的信息','提示',mb_ok+mb_iconinformation);
exit;
end;
end;
end;
cfdyfrm:=tcfdyfrm.create(self);
cfdyfrm.showmodal;
end;

end.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -