电路分析试卷管理系统代码-无忧无虑毕设网_第1页
电路分析试卷管理系统代码-无忧无虑毕设网_第2页
电路分析试卷管理系统代码-无忧无虑毕设网_第3页
电路分析试卷管理系统代码-无忧无虑毕设网_第4页
电路分析试卷管理系统代码-无忧无虑毕设网_第5页
已阅读5页,还剩20页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: 本文配套程序下载地址 : 无忧无虑毕设网 ()-大学生毕业设计站 ,免费毕业设计论文 ,无忧无虑毕设网 大学生毕业设计 ,出售各类毕业设计源码 ,论文 ,程序源码 ,网站源码 ,免费视频教程 ,我们将竭诚为您服务! 附录 题库维护管理代码: interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, ComCtrls, DBTables, ADODB, DB, Grids, DBGrids, Buttons, ExtCtrls, jpeg, Word2000, OleServer; type TfrmTKWH = class(TForm) DataSource1: TDataSource; ADOQuery1: TADOQuery; ADOQuery2: TADOQuery; Label34: TLabel; Panel3: TPanel; PageControl1: TPageControl; SZ_TS: TTabSheet; Label2: TLabel; Label3: TLabel; Label4: TLabel; Label5: TLabel; Label6: TLabel; Label7: TLabel; Label8: TLabel; Label9: TLabel; Label10: TLabel; Label11: TLabel; Bevel1: TBevel; Bevel2: TBevel; Bevel3: TBevel; XZ_DBGrid: TDBGrid; TH_Edit1: TEdit; TM_Edit1: TEdit; XXA_Edit: TEdit; XXC_Edit: TEdit; XXB_Edit: TEdit; XXD_Edit: TEdit; XZtj_BitBtn: TBitBtn; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: XZcx_BitBtn: TBitBtn; XZgx_BitBtn: TBitBtn; XZsc_BitBtn: TBitBtn; XZcxun_BitBtn: TBitBtn; XZ_RadioButton1: TRadioButton; XZ_RadioButton2: TRadioButton; ZJ_ComboBox1: TComboBox; DA_ComboBox: TComboBox; TX_ComboBox1: TComboBox; NY_ComboBox1: TComboBox; TabSheet2: TTabSheet; Label12: TLabel; Label13: TLabel; Label14: TLabel; Label15: TLabel; Label16: TLabel; Label17: TLabel; Label18: TLabel; Label19: TLabel; Label20: TLabel; Label21: TLabel; Bevel4: TBevel; Bevel5: TBevel; Bevel6: TBevel; Label62: TLabel; TK_DBGrid: TDBGrid; TH_Edit2: TEdit; TM_Edit2: TEdit; K_Edit1: TEdit; K_Edit4: TEdit; K_Edit2: TEdit; K_Edit5: TEdit; TKtj_BitBtn: TBitBtn; TKcx_BitBtn: TBitBtn; TKgx_BitBtn: TBitBtn; TKsc_BitBtn: TBitBtn; TKcxun_BitBtn: TBitBtn; TK_RadioButton1: TRadioButton; TK_RadioButton2: TRadioButton; ZJ_ComboBox2: TComboBox; K_ComboBox: TComboBox; TX_ComboBox2: TComboBox; NY_ComboBox2: TComboBox; K_Edit3: TEdit; TabSheet3: TTabSheet; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: Label22: TLabel; Label23: TLabel; Label24: TLabel; Label29: TLabel; Label30: TLabel; Label31: TLabel; Bevel7: TBevel; Bevel8: TBevel; Bevel9: TBevel; JD_DBGrid: TDBGrid; TH_Edit3: TEdit; JDtj_BitBtn: TBitBtn; JDcx_BitBtn: TBitBtn; JDgx_BitBtn: TBitBtn; JDsc_BitBtn: TBitBtn; JDcxun_BitBtn: TBitBtn; JD_RadioButton1: TRadioButton; JD_RadioButton2: TRadioButton; ZJ_ComboBox3: TComboBox; TX_ComboBox3: TComboBox; NY_ComboBox3: TComboBox; DA_Memo1: TMemo; TM_Memo1: TMemo; TabSheet4: TTabSheet; Label25: TLabel; Label26: TLabel; Label27: TLabel; Label28: TLabel; Label32: TLabel; Label33: TLabel; Bevel10: TBevel; Bevel11: TBevel; Bevel12: TBevel; CXSJ_DBGrid: TDBGrid; TH_Edit4: TEdit; CXSJtj_BitBtn: TBitBtn; CXSJcx_BitBtn: TBitBtn; CXSJsc_BitBtn: TBitBtn; CXSJcxun_BitBtn: TBitBtn; CXSJ_RadioButton1: TRadioButton; CXSJ_RadioButton2: TRadioButton; ZJ_ComboBox4: TComboBox; TX_ComboBox4: TComboBox; NY_ComboBox4: TComboBox; DA_Memo2: TMemo; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: TM_Memo2: TMemo; btnCancel: TSpeedButton; CXSJgx_BitBtn: TBitBtn; TabSheet5: TTabSheet; TabSheet6: TTabSheet; ZJ_DBGrid: TDBGrid; Label1: TLabel; XH_Edit: TEdit; Label35: TLabel; ZJXH_Edit: TEdit; Label36: TLabel; ZJM_Edit: TEdit; ZJTJ_BitBtn: TBitBtn; BitBtn2: TBitBtn; ZJXG_BitBtn: TBitBtn; BitBtn4: TBitBtn; JS_DBGrid: TDBGrid; Label37: TLabel; Label38: TLabel; Label39: TLabel; Label40: TLabel; ZJ_ComboBox5: TComboBox; NY_ComboBox5: TComboBox; TX_ComboBox5: TComboBox; TH_Edit5: TEdit; TM_Memo3: TMemo; Label41: TLabel; Label42: TLabel; Bevel13: TBevel; TS_RadioButton1: TRadioButton; TS_RadioButton2: TRadioButton; TS_scBitBtn: TBitBtn; TS_cxunBitBtn6: TBitBtn; TS_cxBitBtn: TBitBtn; TS_tjBitBtn: TBitBtn; TS_gxBitBtn: TBitBtn; Bevel14: TBevel; Bevel15: TBevel; DA_Memo3: TMemo; procedure PageControl1Change(Sender: TObject); procedure FormShow(Sender: TObject); procedure XZ_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); procedure TK_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: procedure JD_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); procedure CXSJ_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); procedure XZ_RadioButton2Click(Sender: TObject); procedure TK_RadioButton2Click(Sender: TObject); procedure JD_RadioButton2Click(Sender: TObject); procedure CXSJ_RadioButton2Click(Sender: TObject); procedure XZgx_BitBtnClick(Sender: TObject); procedure XZtj_BitBtnClick(Sender: TObject); procedure XZcx_BitBtnClick(Sender: TObject); procedure TKgx_BitBtnClick(Sender: TObject); procedure TKtj_BitBtnClick(Sender: TObject); procedure TKcx_BitBtnClick(Sender: TObject); procedure JDgx_BitBtnClick(Sender: TObject); procedure JDtj_BitBtnClick(Sender: TObject); procedure JDcx_BitBtnClick(Sender: TObject); procedure CXSJgx_BitBtnClick(Sender: TObject); procedure CXSJtj_BitBtnClick(Sender: TObject); procedure CXSJcx_BitBtnClick(Sender: TObject); procedure XZcxun_BitBtnClick(Sender: TObject); procedure TKcxun_BitBtnClick(Sender: TObject); procedure JDcxun_BitBtnClick(Sender: TObject); procedure CXSJcxun_BitBtnClick(Sender: TObject); procedure XZsc_BitBtnClick(Sender: TObject); procedure TKsc_BitBtnClick(Sender: TObject); procedure JDsc_BitBtnClick(Sender: TObject); procedure CXSJsc_BitBtnClick(Sender: TObject); procedure CXSJ_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); procedure JD_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); procedure TK_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); procedure XZ_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); procedure ZJ_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); procedure ZJ_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); procedure ZJTJ_BitBtnClick(Sender: TObject); procedure ZJSC_BitBtnClick(Sender: TObject); procedure ZJXG_BitBtnClick(Sender: TObject); procedure ZJCX_BitBtnClick(Sender: TObject); procedure ZJGB_BitBtnClick(Sender: TObject); 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: procedure ZLZJ_BitBtnClick(Sender: TObject); procedure btnCancelClick(Sender: TObject); private Private declarations public Public declarations end; var frmTKWH: TfrmTKWH; implementation uses ShellAPI, uData; $R *.dfm /- /初始化工作 ,题库维护模块的所有控件进行设置 procedure TfrmTKWH.FormShow(Sender: TObject); var temp:string; begin TX_ComboBox1.clear; ZJ_ComboBox1.clear; NY_ComboBox1.Clear; TX_ComboBox2.Clear; K_ComboBox.Clear; ZJ_ComboBox2.Clear; NY_ComboBox2.Clear; TX_ComboBox3.Clear; NY_ComboBox3.Clear; ZJ_ComboBox3.Clear; TX_ComboBox4.Clear; NY_ComboBox4.Clear; ZJ_ComboBox4.clear; TX_ComboBox5.Clear; NY_ComboBox5.Clear; ZJ_ComboBox5.clear; /数据库连接进行设置 ADOQuery1.Connection := dmPer.acPer ; ADOQuery2.Connection := dmPer.acPer ; /初始化工作 ,对各种题型的维护界面进行设置 PageControl1Change(PageControl1); /题库维护模块的控件进行设置 ,包括题型设置 ,难易设置 ,章节设置 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeName From TiXingFen); ADOQuery2.Open; While not ADOQuery2.Eof do begin temp:=ADOQuery2.FieldValuesTypeName; TX_ComboBox1.Items.Add(temp); TX_ComboBox2.Items.Add(temp); TX_ComboBox3.Items.Add(temp); TX_ComboBox4.Items.Add(temp); TX_ComboBox5.Items.Add(temp); ADOQuery2.Next; end; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select NYD From NanYiDj); ADOQuery2.Open; While not ADOQuery2.Eof do begin temp:=ADOQuery2.FieldValuesNYD; NY_ComboBox1.Items.Add(temp); NY_ComboBox2.Items.Add(temp); NY_ComboBox3.Items.Add(temp); NY_ComboBox4.Items.Add(temp); NY_ComboBox5.Items.Add(temp); ADOQuery2.Next; end; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select ZJ,ZJName From ZhangJieJG); ADOQuery2.Open; While not ADOQuery2.Eof do begin temp:=ADOQuery2.FieldValuesZJ+ +ADOQuery2.FieldValuesZJName; ZJ_ComboBox1.Items.Add(temp); ZJ_ComboBox2.Items.Add(temp); ZJ_ComboBox3.Items.Add(temp); ZJ_ComboBox4.Items.Add(temp); ZJ_ComboBox5.Items.Add(temp); ADOQuery2.Next; end; /其他控件设置 XZ_RadioButton1.Checked:=true; XZtj_BitBtn.Enabled:=false; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: XZcx_BitBtn.Enabled:=false; TK_RadioButton1.Checked:=true; TKtj_BitBtn.Enabled:=false; TKcx_BitBtn.Enabled:=false; JD_RadioButton1.Checked:=true; JDtj_BitBtn.Enabled:=false; JDcx_BitBtn.Enabled:=false; CXSJ_RadioButton1.Checked:=true; CXSJtj_BitBtn.Enabled:=false; CXSJcx_BitBtn.Enabled:=false; TS_RadioButton1.Checked:=true; TS_tjBitBtn.Enabled:=false; TS_cxBitBtn.Enabled:=false; end; /- /初始化工作 ,对各种题 型的维护界面进行设置 procedure TfrmTKWH.PageControl1Change(Sender: TObject); begin Case PageControl1.ActivePageIndex of 0:begin /选择题 ADOQuery1.Close; ADOQuery1.SQL.Clear; / ADOQuery1.SQL.Add(Select a.BH,b.TypeName,a.TM,a.A,a.B,a.C,a.D,a.DA,a.CZ,c.NYD,a.TypeID,a.NY from TXuanZe a,TiXingFen b,NanYiDj c where a.TypeID=b.TypeID and a.NY=c.BH ORDER BY a.BH); ADOQuery1.SQL.Add(Select * from TXuanZe); ADOQuery1.Open; XZ_DBGrid.Fields0.DisplayLabel:=题号 ; XZ_DBGrid.Fields1.DisplayLabel:=题型 ; XZ_DBGrid.Fields2.DisplayLabel:=题目 ; XZ_DBGrid.Fields3.DisplayLabel:=选项 A; XZ_DBGrid.Fields4.DisplayLabel:=选项 B; XZ_DBGrid.Fields5.DisplayLabel:=选项 C; XZ_DBGrid.Fields6.DisplayLabel:=选项 d; XZ_DBGrid.Fields7.DisplayLabel:=答案 ; XZ_DBGrid.Fields8.DisplayLabel:=所在章节 ; XZ_DBGrid.Fields9.DisplayLabel:=难易度 ; XZ_DBGrid.Fields0.DisplayWidth:=5; XZ_DBGrid.Fields1.DisplayWidth:=10; XZ_DBGrid.Fields2.DisplayWidth:=20; XZ_DBGrid.Fields3.DisplayWidth:=20; XZ_DBGrid.Fields4.DisplayWidth:=20; XZ_DBGrid.Fields5.DisplayWidth:=20; XZ_DBGrid.Fields6.DisplayWidth:=20; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: XZ_DBGrid.Fields7.DisplayWidth:=5; XZ_DBGrid.Fields8.DisplayWidth:=10; XZ_DBGrid.Fields9.DisplayWidth:=5; end; 1:begin /填空题 ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from TTianKong); ADOQuery1.Open; TK_DBGrid.Fields0.DisplayLabel:=题号 ; TK_DBGrid.Fields1.DisplayLabel:=题型 ; TK_DBGrid.Fields2.DisplayLabel:=题目 ; TK_DBGrid.Fields3.DisplayLabel:=空 1; TK_DBGrid.Fields4.DisplayLabel:=空 2; TK_DBGrid.Fields5.DisplayLabel:=空 3; TK_DBGrid.Fields6.DisplayLabel:=空 4; TK_DBGrid.Fields7.DisplayLabel:=空 5; TK_DBGrid.Fields8.DisplayLabel:=应填空数 ; TK_DBGrid.Fields9.DisplayLabel:=难易度 ; TK_DBGrid.Fields10.DisplayLabel:=所在章节 ; end; 2:begin /简答题 ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from TJianDa); ADOQuery1.Open; JD_DBGrid.Fields0.DisplayLabel:=题号 ; JD_DBGrid.Fields1.DisplayLabel:=题型 ; JD_DBGrid.Fields2.DisplayLabel:=题目 ; JD_DBGrid.Fields3.DisplayLabel:=答案 ; JD_DBGrid.Fields4.DisplayLabel:=难易 ; JD_DBGrid.Fields5.DisplayLabel:=所在章节 ; end; 3:begin /程序设计题 ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from TChengxu); ADOQuery1.Open; CXSJ_DBGrid.Fields0.DisplayLabel:=题号 ; CXSJ_DBGrid.Fields1.DisplayLabel:=题型 ; CXSJ_DBGrid.Fields2.DisplayLabel:=题目 ; CXSJ_DBGrid.Fields3.DisplayLabel:=答案 ; CXSJ_DBGrid.Fields4.DisplayLabel:=难易 ; CXSJ_DBGrid.Fields5.DisplayLabel:=所在章节 ; end; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: 4:begin /程序设计题 ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from Tjisuan); ADOQuery1.Open; JS_DBGrid.Fields0.DisplayLabel:=题号 ; JS_DBGrid.Fields1.DisplayLabel:=题型 ; JS_DBGrid.Fields2.DisplayLabel:=题目 ; JS_DBGrid.Fields3.DisplayLabel:=答案 ; JS_DBGrid.Fields4.DisplayLabel:=难易 ; JS_DBGrid.Fields5.DisplayLabel:=所在章节 ; end; 5:begin ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from ZhangJieJG); ADOQuery1.Open; ZJ_DBGrid.Fields0.DisplayLabel:=序号 ; ZJ_DBGrid.Fields1.DisplayLabel:=章节序号 ; ZJ_DBGrid.Fields2.DisplayLabel:=章节名 ; end; end; end; /- /选择题维护界面 响应鼠标点击操作 procedure TfrmTKWH.XZ_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); var temp,temp1,temp11:integer; temp2,temp3,temp4,temp5,temp6,temp7,temp8,temp9,temp10:string; begin temp:=ADOQuery1.fieldbyname(BH).AsInteger; temp2:=ADOQuery1.fieldbyname(TM).AsString; temp3:=ADOQuery1.fieldbyname(A).AsString; temp4:=ADOQuery1.fieldbyname(B).AsString; temp5:=ADOQuery1.fieldbyname(C).AsString; temp6:=ADOQuery1.fieldbyname(D).AsString; temp7:=ADOQuery1.fieldbyname(DA).AsString; temp8:=ADOQuery1.fieldbyname(CZ).AsString; temp1:=ADOQuery1.fieldbyname(TypeID).AsInteger; temp11:=ADOQuery1.fieldbyname(NY).AsInteger; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeName From TiXingFen Where TypeID=:temp1); 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: ADOQuery2.Parameters.ParamByName(temp1).Value:=temp1; ADOQuery2.Open; temp10:=ADOQuery2.Fieldbyname(TypeName).AsString; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select NYD From NanYiDj Where BH=:temp11); ADOQuery2.Parameters.ParamByName(temp11).Value:=temp11; ADOQuery2.Open; temp9:=ADOQuery2.Fieldbyname(NYD).AsString; TH_Edit1.Text:=IntToStr(temp); TX_ComboBox1.Text:=temp10; TM_Edit1.Text:=temp2; XXA_Edit.Text:=temp3; XXB_Edit.Text:=temp4; XXC_Edit.Text:=temp5; XXD_Edit.Text:=temp6; DA_ComboBox.Text:=temp7; ZJ_ComboBox1.Text:=temp8; NY_ComboBox1.Text:=temp9; end; /- /填空题维护界面 响应鼠标点击操作 procedure TfrmTKWH.TK_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); var temp,temp1,temp11:integer; temp2,temp3,temp4,temp5,temp6,temp7,temp8,temp9,temp10,temp12:string; begin temp:=ADOQuery1.fieldbyname(BH).AsInteger; temp2:=ADOQuery1.fieldbyname(TM).AsString; temp3:=ADOQuery1.fieldbyname(K1).AsString; temp4:=ADOQuery1.fieldbyname(K2).AsString; temp5:=ADOQuery1.fieldbyname(K3).AsString; temp6:=ADOQuery1.fieldbyname(K4).AsString; temp7:=ADOQuery1.fieldbyname(K5).AsString; temp8:=ADOQuery1.fieldbyname(YTS).AsString; temp9:=ADOQuery1.fieldbyname(CZ).AsString; temp1:=ADOQuery1.fieldbyname(TypeID).AsInteger; temp11:=ADOQuery1.fieldbyname(NY).AsInteger; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeName From TiXingFen Where TypeID=:temp1); ADOQuery2.Parameters.ParamByName(temp1).Value:=temp1; ADOQuery2.Open; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: temp10:=ADOQuery2.Fieldbyname(TypeName).AsString; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select NYD From NanYiDj Where BH=:temp11); ADOQuery2.Parameters.ParamByName(temp11).Value:=temp11; ADOQuery2.Open; temp12:=ADOQuery2.Fieldbyname(NYD).AsString; TH_Edit2.Text:=IntToStr(temp); TX_ComboBox2.Text:=temp10; TM_Edit2.Text:=temp2; K_Edit1.Text:=temp3; K_Edit2.Text:=temp4; K_Edit3.Text:=temp5; K_Edit4.Text:=temp6; K_Edit5.Text:=temp7; K_ComboBox.Text:=temp8; ZJ_ComboBox2.Text:=temp9; NY_ComboBox2.Text:=temp12; end; /- /简答题维护界面 响应鼠标点击操作 procedure TfrmTKWH.JD_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); var temp,temp1,temp11:integer; temp2,temp3,temp4,temp5,temp6:string; begin temp:=ADOQuery1.fieldbyname(BH).AsInteger; temp2:=ADOQuery1.fieldbyname(TM).AsString; temp3:=ADOQuery1.fieldbyname(DA).AsString; temp4:=ADOQuery1.fieldbyname(CZ).AsString; temp1:=ADOQuery1.fieldbyname(TypeID).AsInteger; temp11:=ADOQuery1.fieldbyname(NY).AsInteger; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeName From TiXingFen Where TypeID=:temp1); ADOQuery2.Parameters.ParamByName(temp1).Value:=temp1; ADOQuery2.Open; temp5:=ADOQuery2.Fieldbyname(TypeName).AsString; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select NYD From NanYiDj Where BH=:temp11); ADOQuery2.Parameters.ParamByName(temp11).Value:=temp11; ADOQuery2.Open; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: temp6:=ADOQuery2.Fieldbyname(NYD).AsString; TH_Edit3.Text:=IntToStr(temp); TX_ComboBox3.Text:=temp5; TM_Memo1.Text:=temp2; DA_Memo1.Text:=temp3; ZJ_ComboBox3.Text:=temp4; NY_ComboBox3.Text:=temp6; end; /- /程序设计题维护界面 响应鼠标点击操作 procedure TfrmTKWH.CXSJ_DBGridMouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); var temp,temp1,temp11:integer; temp2,temp3,temp4,temp5,temp6:string; begin temp:=ADOQuery1.fieldbyname(BH).AsInteger; temp2:=ADOQuery1.fieldbyname(TM).AsString; temp3:=ADOQuery1.fieldbyname(DA).AsString; temp4:=ADOQuery1.fieldbyname(CZ).AsString; temp1:=ADOQuery1.fieldbyname(TypeID).AsInteger; temp11:=ADOQuery1.fieldbyname(NY).AsInteger; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeName From TiXingFen Where TypeID=:temp1); ADOQuery2.Parameters.ParamByName(temp1).Value:=temp1; ADOQuery2.Open; temp5:=ADOQuery2.Fieldbyname(TypeName).AsString; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select NYD From NanYiDj Where BH=:temp11); ADOQuery2.Parameters.ParamByName(temp11).Value:=temp11; ADOQuery2.Open; temp6:=ADOQuery2.Fieldbyname(NYD).AsString; TH_Edit4.Text:=IntToStr(temp); TX_ComboBox4.Text:=temp5; TM_Memo2.Text:=temp2; DA_Memo2.Text:=temp3; ZJ_ComboBox4.Text:=temp4; NY_ComboBox4.Text:=temp6; end; procedure TfrmTKWH.XZ_RadioButton2Click(Sender: TObject); begin 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: ADOQuery1.Close; ADOQuery1.CursorType:=ctKeyset; ADOQuery1.Open; XZtj_BitBtn.Enabled:=true; XZcx_BitBtn.Enabled:=true; end; procedure TfrmTKWH.TK_RadioButton2Click(Sender: TObject); begin ADOQuery1.Close; ADOQuery1.CursorType:=ctKeyset; ADOQuery1.Open; TKtj_BitBtn.Enabled:=true; TKcx_BitBtn.Enabled:=true; end; procedure TfrmTKWH.JD_RadioButton2Click(Sender: TObject); begin ADOQuery1.Close; ADOQuery1.CursorType:=ctKeyset; ADOQuery1.Open; JDtj_BitBtn.Enabled:=true; JDcx_BitBtn.Enabled:=true; end; procedure TfrmTKWH.CXSJ_RadioButton2Click(Sender: TObject); begin ADOQuery1.Close; ADOQuery1.CursorType:=ctKeyset; ADOQuery1.Open; CXSJtj_BitBtn.Enabled:=true; CXSJcx_BitBtn.Enabled:=true; end; procedure TfrmTKWH.XZgx_BitBtnClick(Sender: TObject); var temp:string; temp1:integer; begin if TX_ComboBox1.Text= then showmessage(题型不能为空! ) else if DA_ComboBox.Text= then showmessage(答案不能为空! ) else if ZJ_ComboBox1.Text= then showmessage(所在章节不能为空! ) else if TM_Edit1.Text= then showmessage(题目不能为空 ! ) else if NY_ComboBox1.Text= then showmessage(难易度不能为空! ) 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: else if XXA_Edit.Text= then showmessage(答案 A 不能为空 ) else if XXB_Edit.Text= then showmessage(答案 B 不能为空 ) else if XXC_Edit.Text= then showmessage(答案 C 不能为空 ) else if XXD_Edit.Text= then showmessage(答案 D 不能为空 ) else begin ADOQuery1.Edit; temp:=TX_ComboBox1.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeID from TiXingFen where TypeName=:temp); ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesTypeID; ADOQuery1.Fields.FieldByName(TypeID).AsInteger:=temp1; ADOQuery1.Fields.FieldByName(TM).AsString:=TM_Edit1.Text; ADOQuery1.Fields.FieldByName(A).AsString:=XXA_Edit.Text; ADOQuery1.Fields.FieldByName(B).AsString:=XXB_Edit.Text; ADOQuery1.Fields.FieldByName(C).AsString:=XXC_Edit.Text; ADOQuery1.Fields.FieldByName(D).AsString:=XXD_Edit.Text; ADOQuery1.Fields.FieldByName(DA).AsString:=DA_ComboBox.Text; ADOQuery1.Fields.FieldByName(CZ).AsString:=ZJ_ComboBox1.Text; temp:=NY_ComboBox1.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select BH from NanYiDj where NYD=:temp); ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesBH; ADOQuery1.Fields.FieldByName(NY).AsInteger:=temp1; if not XZ_Radiobutton2.Checked then ADOQuery1.Post; showmessage(更新成功 ); end; end; procedure TfrmTKWH.XZtj_BitBtnClick(Sender: TObject); begin if XZ_Radiobutton2.Checked then ADOQuery1.UpdateBatch(); showmessage(提交完成! ); end; procedure TfrmTKWH.XZcx_BitBtnClick(Sender: TObject); begin if XZ_Radiobutton2.Checked then 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: ADOQuery1.CancelBatch(); end; procedure TfrmTKWH.TKgx_BitBtnClick(Sender: TObject); var temp:string; temp1:integer; begin if TX_ComboBox2.Text= then showmessage(题型不能为空! ) else if K_ComboBox.Text= then showmessage(空数不能为空! ) else if ZJ_ComboBox2.Text= then showmessage(所在章节不能为空! ) else if TM_Edit2.Text= then showmessage(题目不能为空! ) else if NY_ComboBox2.Text= then showmessage(难易度不能为空! ) else begin ADOQuery1.Edit; temp:=TX_ComboBox2.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeID from TiXingFen where TypeName=:temp); ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesTypeID; ADOQuery1.Fields.FieldByName(TypeID).AsInteger:=temp1; ADOQuery1.Fields.FieldByName(TM).AsString:=TM_Edit2.Text; ADOQuery1.Fields.FieldByName(K1).AsString:=K_Edit1.Text; ADOQuery1.Fields.FieldByName(K2).AsString:=K_Edit2.Text; ADOQuery1.Fields.FieldByName(K3).AsString:=K_Edit3.Text; ADOQuery1.Fields.FieldByName(K4).AsString:=K_Edit4.Text; ADOQuery1.Fields.FieldByName(K5).AsString:=K_Edit5.Text; ADOQuery1.Fields.FieldByName(YTS).AsInteger:=StrToInt(K_ComboBox.Text); ADOQuery1.Fields.FieldByName(CZ).AsString:=ZJ_ComboBox2.Text; temp:=NY_ComboBox2.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select BH from NanYiDj where NYD=:temp); ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesBH; ADOQuery1.Fields.FieldByName(NY).AsInteger:=temp1; if not TK_Radiobutton2.Checked then ADOQuery1.Post; showmessage(更新成功 ); end; end; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: procedure TfrmTKWH.TKtj_BitBtnClick(Sender: TObject); begin if TK_Radiobutton2.Checked then ADOQuery1.UpdateBatch(); showmessage(提交完成! ); end; procedure TfrmTKWH.TKcx_BitBtnClick(Sender: TObject); begin if TK_Radiobutton2.Checked then ADOQuery1.CancelBatch(); end; procedure TfrmTKWH.JDgx_BitBtnClick(Sender: TObject); var temp:string; temp1:integer; begin if TX_ComboBox3.Text= then showmessage(题型不能为空! ) else if DA_Memo1.Text= then showmessage(答案不能为空! ) else if ZJ_ComboBox3.Text= then showmessage(所在章节不能为空! ) else if TM_Memo1.Text= then showmessage(题目不能为空! ) else if NY_ComboBox3.Text= then showmessage(难易度不能为空! ) else begin ADOQuery1.Edit; temp:=TX_ComboBox3.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeID from TiXingFen where TypeName=:temp); ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesTypeID; ADOQuery1.Fields.FieldByName(TypeID).AsInteger:=temp1; ADOQuery1.Fields.FieldByName(TM).AsString:=TM_Memo1.Text; ADOQuery1.Fields.FieldByName(DA).AsString:=DA_Memo1.Text; ADOQuery1.Fields.FieldByName(CZ).AsString:=ZJ_ComboBox3.Text; temp:=NY_ComboBox3.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select BH from NanYiDj where NYD=:temp); ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesBH; ADOQuery1.Fields.FieldByName(NY).AsInteger:=temp1; if not JD_Radiobutton2.Checked then 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: ADOQuery1.Post; showmessage(更新成功 ); end; end; procedure TfrmTKWH.JDtj_BitBtnClick(Sender: TObject); begin if JD_Radiobutton2.Checked then ADOQuery1.UpdateBatch(); showmessage(提交完成! ); end; procedure TfrmTKWH.JDcx_BitBtnClick(Sender: TObject); begin if JD_Radiobutton2.Checked then ADOQuery1.CancelBatch(); end; procedure TfrmTKWH.CXSJgx_BitBtnClick(Sender: TObject); var temp:string; temp1:integer; begin if TX_ComboBox4.Text= then showmessage(题型不能为空! ) else if DA_Memo2.Text= then showmessage(答案不能为空! ) else if ZJ_ComboBox4.Text= then showmessage(所在章节不能为空! ) else if TM_Memo2.Text= then showmessage(题目不能为空! ) else if NY_ComboBox4.Text= then showmessage(难易度不能为空! ) else begin ADOQuery1.Edit; temp:=TX_ComboBox4.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select TypeID from TiXingFen where TypeName=:temp); ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesTypeID; ADOQuery1.Fields.FieldByName(TypeID).AsInteger:=temp1; ADOQuery1.Fields.FieldByName(TM).AsString:=TM_Memo2.Text; ADOQuery1.Fields.FieldByName(DA).AsString:=DA_Memo2.Text; ADOQuery1.Fields.FieldByName(CZ).AsString:=ZJ_ComboBox4.Text; temp:=NY_ComboBox4.Text; ADOQuery2.Close; ADOQuery2.SQL.Clear; ADOQuery2.SQL.Add(Select BH from NanYiDj where NYD=:temp); 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: ADOQuery2.Parameters.ParamByName(temp).Value:=temp; ADOQuery2.Open; temp1:=ADOQuery2.FieldValuesBH; ADOQuery1.Fields.FieldByName(NY).AsInteger:=temp1; if not CXSJ_Radiobutton2.Checked then ADOQuery1.Post; showmessage(更新成功 ); end; end; procedure TfrmTKWH.CXSJtj_BitBtnClick(Sender: TObject); begin if CXSJ_Radiobutton2.Checked then ADOQuery1.UpdateBatch; showmessage(提交完成! ); end; procedure TfrmTKWH.CXSJcx_BitBtnClick(Sender: TObject); begin if CXSJ_Radiobutton2.Checked then ADOQuery1.CancelBatch(); end; procedure TfrmTKWH.XZcxun_BitBtnClick(Sender: TObject); var temp:string; begin temp:=ZJ_ComboBox1.Text; ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from TXuanZe where CZ=:temp); ADOQuery1.Parameters.ParamByName(temp).Value:=temp; ADOQuery1.Open; end; procedure TfrmTKWH.TKcxun_BitBtnClick(Sender: TObject); var temp:string; begin temp:=ZJ_ComboBox2.Text; ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from TTianKong where CZ=:temp); ADOQuery1.Parameters.ParamByName(temp).Value:=temp; ADOQuery1.Open; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: end; procedure TfrmTKWH.JDcxun_BitBtnClick(Sender: TObject); var temp:string; begin temp:=ZJ_ComboBox3.Text; ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from TJianDa where CZ=:temp); ADOQuery1.Parameters.ParamByName(temp).Value:=temp; ADOQuery1.Open; end; procedure TfrmTKWH.CXSJcxun_BitBtnClick(Sender: TObject); var temp:string; begin temp:=ZJ_ComboBox4.Text; ADOQuery1.Close; ADOQuery1.SQL.Clear; ADOQuery1.SQL.Add(Select * from TChengxu where CZ=:temp); ADOQuery1.Parameters.ParamByName(temp).Value:=temp; ADOQuery1.Open; end; procedure TfrmTKWH.XZsc_BitBtnClick(Sender: TObject); var Flag:integer; begin Flag:=messagebox(handle, 你 确 定 要 删 除 此 条 记 录 吗 ? , 删除 ,MB_YESNO or MB_ICONINFORMATION); if Flag=idno then exit; ADOQuery1.Delete; end; procedure TfrmTKWH.TKsc_BitBtnClick(Sender: TObject); var Flag:integer; begin Flag:=messagebox(handle, 你 确 定 要 删 除 此 条 记 录 吗 ? , 删除 ,MB_YESNO or MB_ICONINFORMATION); if Flag=idno then exit; ADOQuery1.Delete; end; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: procedure TfrmTKWH.JDsc_BitBtnClick(Sender: TObject); var Flag:integer; begin Flag:=messagebox(handle, 你 确 定 要 删 除 此 条 记 录 吗 ? , 删除 ,MB_YESNO or MB_ICONINFORMATION); if Flag=idno then exit; ADOQuery1.Delete; end; procedure TfrmTKWH.CXSJsc_BitBtnClick(Sender: TObject); var Flag:integer; begin Flag:=messagebox(handle, 你 确 定 要 删 除 此 条 记 录 吗 ? , 删除 ,MB_YESNO or MB_ICONINFORMATION); if Flag=idno then exit; ADOQuery1.Delete; end; procedure TfrmTKWH.CXSJ_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); begin if (Column.Field.DataType=ftMemo) then begin CXSJ_DBGrid.Canvas.TextRect(Rect,Rect.Left,Rect.Top,Column.Field.AsString); end else CXSJ_DBGrid.DefaultDrawColumnCell(Rect,DataCol,Column,State); end; procedure TfrmTKWH.JD_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); begin if (Column.Field.DataType=ftMemo) then begin JD_DBGrid.Canvas.TextRect(Rect,Rect.Left,Rect.Top,Column.Field.AsString); end else JD_DBGrid.DefaultDrawColumnCell(Rect,DataCol,Column,State); end; 无忧无虑毕设网 ():毕业设计源码下载 毕业设计源码下载: procedure TfrmTKWH.TK_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); begin if (Column.Field.DataType=ftMemo) then begin TK_DBGrid.Canvas.TextRect(Rect,Rect.Left,Rect.Top,Column.Field.AsString); end else TK_DBGrid.DefaultDrawColumnCell(Rect,DataCol,Column,State); end; procedure TfrmTKWH.XZ_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); begin if (Column.Field.DataType=ftMemo) then begin XZ_DBGrid.Canvas.TextRect(Rect,Rect.Left,Rect.Top,Column.Field.AsString); end else XZ_DBGrid.DefaultDrawColumnCell(Rect,DataCol,Column,State); end; procedure TfrmTKWH.ZJ_DBGridDrawColumnCell(Sender: TObject; const Rect: TRect; DataCol: Integer; Column: TColumn; State: TGridDrawState); begin if (Column.Field.DataType=ftMemo) then begin ZJ_DBGrid.Canvas.TextRect(Rect,Rect.Left,Rect.Top,Column.Field.AsString); end else ZJ_DBGrid.Def

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

评论

0/150

提交评论