版權(quán)說(shuō)明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡(jiǎn)介
1、畢業(yè)設(shè)計(jì)畢業(yè)設(shè)計(jì) 院系院系_ 專業(yè)專業(yè)_ 班級(jí)班級(jí)_ 姓名姓名_ 日期日期 年年 月月 日日 摘摘 要要 20 世紀(jì)以來(lái),社會(huì)生產(chǎn)力迅速發(fā)展,科學(xué)技術(shù)突飛猛 進(jìn),人們進(jìn)行信息交流的深度與廣度不斷增加,信息量急 劇增長(zhǎng),傳統(tǒng)的信息處理與決策的手段已不能適應(yīng)社會(huì)的 需要,信息的重要性和信息處理問(wèn)題的緊迫性空前提高了, 面對(duì)著日益復(fù)雜和不斷發(fā)展,變化的社會(huì)環(huán)境,特別是企 業(yè)間日趨劇烈的競(jìng)爭(zhēng)形勢(shì),一個(gè)人、一個(gè)企業(yè)要在現(xiàn)代社 會(huì)中求生存,求發(fā)展,必須具備足夠的信息和強(qiáng)有力的信 息收集與處理手段。 對(duì)于一個(gè)學(xué)校來(lái)說(shuō),大量教師信息,學(xué)生管理信息,教 職工日常工資管理,學(xué)生成績(jī)管理,以及學(xué)生評(píng)語(yǔ)的生成還 有基
2、本數(shù)據(jù)的維護(hù)都難于通過(guò)傳統(tǒng)的方法進(jìn)行管理;這就 迫切需要利用計(jì)算機(jī)技術(shù)來(lái)幫助學(xué)校管理者來(lái)處理這些日 常管理.電子教務(wù)管理系統(tǒng)是管理信息系統(tǒng)的一個(gè)典型用例. 管理信息系統(tǒng)是一個(gè)集信息技術(shù)、經(jīng)濟(jì)管理理論、統(tǒng) 計(jì)學(xué)與運(yùn)籌學(xué)、數(shù)據(jù)庫(kù)技術(shù)為一體的綜合性系統(tǒng),是一個(gè) 資金技術(shù)密集型、勞動(dòng)密集型、智力密集型的項(xiàng)目。我國(guó) 擁有廣闊的市場(chǎng)和豐富的人才資源,有幾十年的技術(shù)積累 和經(jīng)驗(yàn)積累,有一定的后發(fā)優(yōu)勢(shì)。管理信息系統(tǒng)的創(chuàng)新工 作既不能妄自菲薄,更不能夜郎自大。要抓住當(dāng)前網(wǎng)絡(luò)經(jīng) 濟(jì)興起的有利時(shí)機(jī),以實(shí)現(xiàn)我國(guó)信息技術(shù)和信息產(chǎn)業(yè)的跨 越式發(fā)展,更好地發(fā)揮信息產(chǎn)業(yè)對(duì)國(guó)民經(jīng)濟(jì)增長(zhǎng)的拉動(dòng)作 用。 開發(fā)電子教務(wù)管理系統(tǒng)的過(guò)程
3、就是要實(shí)現(xiàn)數(shù)據(jù)處理方 式由人工管理向計(jì)算機(jī)管理的轉(zhuǎn)變,它在計(jì)算機(jī)技術(shù)和教 務(wù)管理實(shí)踐活動(dòng)兩者之間架設(shè)橋梁。 關(guān)鍵字:教務(wù)管理,管理信息系統(tǒng),數(shù)據(jù)庫(kù),計(jì)算機(jī)管理 abstractabstract: since the 20th century, the rapid development of social productive forces, science and technology, exchange of information is the depth and scope of increasing the volume of information rapid growth, th
4、e traditional information processing and decision-making tools have not the needs of the community, the importance of information and information processing problems urgency unprecedented increase, in the face of increasingly complex and evolving. changes in the social environment, in particular the
5、 increasingly keen competition among enterprises situation, a person or an enterprise to survive in modern society, and development, we must have sufficient information and powerful information gathering and processing tools. for a school, a lot of information for teachers, student information manag
6、ement, the teaching and administrative staff daily wage management, student performance management, and the comments students have generated the basic data are difficult to maintain through traditional means; this urgent need for using computer technology to help school managers to deal with these d
7、ay-to-day management. academic management system is an electronic information management system with a typical cases. management information system is a collection of information technology, economic management theory, statistics and research, database integration technology for the integrated syste
8、m is a capital-and technology-intensive and labor-intensive, intellectual-intensive projects. china has a vast market and abundant human resources, technical accumulation and decades of accumulated experience, a certain advantages. mis innovation can not sell, not self- assertive. we should seize th
9、e current favorable opportunity to network economy, chinas information technology and to achieve a leap forward of the information industry, give better play to the information industry to stimulate economic growth. development of electronic academic course management system approach is to be achiev
10、ed by manual data management to computer management changes in computer technology and academic build bridges between management practice. keyword: academic management, management information systems, databases, computer management 目目 錄錄 摘 要i abstractii 第一章 引言 1 1.1 背景1 1.1.1 電子教務(wù)管理系統(tǒng)1 1.2 開發(fā)電子教務(wù)管理系
11、統(tǒng)的目的和原則 3 1.3 開發(fā)環(huán)境介紹3 1.3.1 開發(fā)平臺(tái)4 1.3.2 數(shù)據(jù)庫(kù)設(shè)計(jì)工具access 數(shù)據(jù)庫(kù)管理系統(tǒng) 7 第二章 系統(tǒng)設(shè)計(jì)9 2.1 系統(tǒng)分析 9 2.2 系統(tǒng)流程和操作方式設(shè)計(jì)11 第三章 系統(tǒng)界面設(shè)計(jì) 12 3.1 系統(tǒng)界面設(shè)計(jì)以及代碼分析 12 第四章 數(shù)據(jù)庫(kù)的設(shè)計(jì)30 4.1 數(shù)據(jù)庫(kù)設(shè)計(jì)30 4.2 數(shù)據(jù)庫(kù)概念和發(fā)展 30 4.3 系統(tǒng)測(cè)試與評(píng)價(jià) 38 總 結(jié) 39 致 謝40 參考文獻(xiàn)41 第一章第一章 引言引言 對(duì)于一個(gè)學(xué)校來(lái)說(shuō),大量教師信息,學(xué)生管理信息,教 職工日常工資管理,學(xué)生成績(jī)管理,以及學(xué)生評(píng)語(yǔ)的生成還 有基本數(shù)據(jù)的維護(hù)都難于通過(guò)傳統(tǒng)的方法進(jìn)行管理;
12、這就 迫切需要利用計(jì)算機(jī)技術(shù)來(lái)幫助學(xué)校管理者來(lái)處理這些日 常管理.電子教務(wù)管理系統(tǒng)是管理信息系統(tǒng)的一個(gè)典型用例. 1.1 背景背景 1.1.1 電子教務(wù)管理系統(tǒng)電子教務(wù)管理系統(tǒng) 開發(fā)電子教務(wù)管理系統(tǒng)的過(guò)程就是要實(shí)現(xiàn)數(shù)據(jù)處理方 式由人工管理向計(jì)算機(jī)管理的轉(zhuǎn)變,它在計(jì)算機(jī)技術(shù)和教 務(wù)管理實(shí)踐活動(dòng)兩者之間架設(shè)橋梁。 1.21.2 開發(fā)電子教務(wù)管理系統(tǒng)的目的和原則開發(fā)電子教務(wù)管理系統(tǒng)的目的和原則 電子教務(wù)系統(tǒng)只要服務(wù)于高校管理者方便管理本校教職 員工,學(xué)生的基本信息如教師工資福利,學(xué)生成績(jī)信息學(xué)籍 管理等. 1.3 開發(fā)環(huán)境介紹開發(fā)環(huán)境介紹 1.3.1 開發(fā)平臺(tái)開發(fā)平臺(tái) 本電子教務(wù)管理系統(tǒng)的開發(fā)平臺(tái)為
13、微軟 windows xp visual basic 6.0 以及微軟的 access 作為操作數(shù)據(jù)庫(kù). .2 數(shù)據(jù)庫(kù)設(shè)計(jì)工具數(shù)據(jù)庫(kù)設(shè)計(jì)工具accessaccess 數(shù)據(jù)庫(kù)管理系統(tǒng)數(shù)據(jù)庫(kù)管理系統(tǒng) microsoft access 介紹: 使用 microsoft access,可以在單一的數(shù)據(jù)庫(kù)文件中管 理所有的信息。在這個(gè)文件中,用戶可以將自己的數(shù)據(jù) 分別保存在各自獨(dú)立的存儲(chǔ)空間中,這些空間稱作表; 可以使用聯(lián)機(jī)窗體來(lái)查看、添加及更新表中的數(shù)據(jù);使 用查詢來(lái)查找并檢索所要的數(shù)據(jù);也可以使用報(bào)表以特 定的版面布置來(lái)分析及打印數(shù)據(jù)。 如果要保存數(shù)據(jù),請(qǐng)為每一種類型的信息創(chuàng)建一個(gè)表
14、。 如果要從查詢、窗體或報(bào)表中的多個(gè)表中將數(shù)據(jù)合并在 一起,就要定義各個(gè)表之間的關(guān)系。 如果要搜索并檢索符合指定條件的數(shù)據(jù),包括來(lái)自多 個(gè)表中的數(shù)據(jù),就要?jiǎng)?chuàng)建查詢。查詢的同時(shí)也可以更新 或刪除多條記錄,并對(duì)數(shù)據(jù)執(zhí)行內(nèi)嵌或自定義的計(jì)算。 如果要簡(jiǎn)單地直接在某個(gè)表中查看、輸入及更改數(shù)據(jù), 請(qǐng)創(chuàng)建一個(gè)窗體。在打開一個(gè)窗體時(shí), microsoft access 將從一個(gè)或多個(gè)表中檢索數(shù)據(jù),并使 用用戶在“窗體向?qū)А边x擇的版面布局或所創(chuàng)建的版面 布局,將窗體顯示在屏幕上。 如果要分析數(shù)據(jù)或?qū)?shù)據(jù)以特定的方式打印出來(lái),請(qǐng) 創(chuàng)建一個(gè)報(bào)表。例如,可以打印一份將數(shù)據(jù)分組并計(jì)算 數(shù)據(jù)總和的報(bào)表,也可以打印另一份帶
15、有各種數(shù)據(jù)格式 的打印郵件標(biāo)簽的報(bào)表。 第二章第二章 系統(tǒng)設(shè)計(jì)系統(tǒng)設(shè)計(jì) 2.12.1 系統(tǒng)分析系統(tǒng)分析 本電子教務(wù)管理系統(tǒng)主要由以下幾大模塊構(gòu)成. 一.通用模塊(教工信息管理,學(xué)生信息管理,評(píng)語(yǔ)管系統(tǒng),考 試管理系統(tǒng),基礎(chǔ)數(shù)據(jù)維護(hù),窗口,操作員命令) 二.超級(jí)信史,系統(tǒng)助手 2.22.2 系統(tǒng)流程和操作方式設(shè)計(jì)系統(tǒng)流程和操作方式設(shè)計(jì) 窗口 程序登陸 主界面 教職 工信 息管 理 學(xué)生 信息 管理 評(píng) 語(yǔ) 管 理 系 統(tǒng) 考試 管理 系統(tǒng) 基 礎(chǔ) 數(shù) 據(jù) 維 護(hù) 窗 口 操作 員命 令 第三章第三章 系統(tǒng)界面設(shè)計(jì)系統(tǒng)界面設(shè)計(jì) 3.13.1 系統(tǒng)界面設(shè)計(jì)系統(tǒng)界面設(shè)計(jì) 1.1.登陸界面登陸界面 代碼
16、設(shè)計(jì)代碼設(shè)計(jì): : private sub cmbuser_keypress(keyascii as integer) if keyascii = 13 then cmdok_click end sub private sub cmdcancel_click() me.hide end sub private sub cmdok_click() dim txtsql as string set mrc = new adodb.recordset if trim(cmbuser.text) = then cmbuser.setfocus else txtsql = select * from l
17、ogin where 登錄姓名 = & cmbuser.text & mrc.open trim$(txtsql), con, adopenkeyset, adlockoptimistic set executesql = mrc if mrc.eof = true then cmbuser.setfocus else if trim(mrc!密碼) = trim(txtpassword.text) then loginuser = mrc!登錄姓名 permission = mrc!權(quán)限 if check1.value = 1 then r = writeprivateprofilestri
18、ng(用戶信息 , 姓名, cmbuser.text, app.path + 電子教務(wù)系統(tǒng).ini) s = writeprivateprofilestring(用戶信息 , 密碼, txtpassword.text, app.path + 電子教務(wù)系統(tǒng).ini) if r 1 or s 1 then msgbox 寫基本信息出錯(cuò)!, 48, app.title end if else r = writeprivateprofilestring(用戶信息 , 姓名, , app.path + 電子教務(wù)系統(tǒng).ini) s = writeprivateprofilestring(用戶信息 , 密碼
19、, , app.path + 電子教務(wù)系統(tǒng).ini) end if mrc.close me.hide exit sub else txtpassword.setfocus txtpassword.text = end if end if end if micount = micount + 1 msgbox 登錄錯(cuò)誤,你還有 & 3 - micount & 次機(jī)會(huì)!, vbokonly + vbexclamation, 警告 if micount = 3 then me.hide end if exit sub end sub private sub form_load() if len(g
20、etfromini(用戶信息, 姓名, app.path + 電子教務(wù) 系統(tǒng).ini) = 0 or len(getfromini(用戶信息, 密碼, app.path + 電子教務(wù)系統(tǒng).ini) = 0 then else cmbuser.text = getfromini(用戶信息, 姓名, app.path + 電子教務(wù)系統(tǒng).ini) txtpassword.text = getfromini(用戶信息, 密碼, app.path + 電子教務(wù)系統(tǒng).ini) end if dim rs1 as adodb.recordset set rs1 = new adodb.recordset r
21、s1.open login, con, adopenstatic, adcmdtable icount = 0 if rs1.bof and rs1.eof then msgbox 請(qǐng)用管理員賬號(hào)登錄 exit sub end if rs1.movefirst do while rs1.eof = false cmbuser.additem rs1!登錄姓名, i i = i + 1 rs1.movenext loop end sub private sub txtpassword_keypress(keyascii as integer) if keyascii = 13 then cmdo
22、k_click end sub 2.2.智能成績(jī)添加界面設(shè)計(jì)智能成績(jī)添加界面設(shè)計(jì) 界面設(shè)計(jì)界面設(shè)計(jì): : 代碼設(shè)計(jì)代碼設(shè)計(jì): : dim ksxz as string dim xxkbl as double dim bj as integer dim i as integer dim icount as integer dim addflg as boolean dim rscount as integer dim rs as adodb.recordset dim rs1 as adodb.recordset dim cmdexe as adodb.command private sub c
23、ommand13_click() sstab1.tab = 0 end sub private sub command5_click() unload me end sub private sub command7_click() pass rs.open select * from 學(xué)籍表 where 班級(jí)= & trim(combo1.text) & order by 學(xué)號(hào), con, adopenstatic, adlockpessimistic, adcmdtext if rs.eof = true and rs.bof = true then command1.enabled = f
24、alse command2.enabled = false command3.enabled = false command4.enabled = false command13.enabled = false rs.close msgbox 請(qǐng)到學(xué)籍表中添加學(xué)生名單!, , 此班沒(méi)有學(xué)生: exit sub else frame1.enabled = false frame2.enabled = false command1.enabled = true command2.enabled = true command3.enabled = true command4.enabled = tr
25、ue command7.enabled = false command8.enabled = true command9.enabled = true command13.enabled = true msgbox trim(combo1.text) & 登分: & chr(13) & 考試性 質(zhì): & trim(text1.text) & chr(13) & 可以開始輸入成績(jī)了!, , app.title command13.setfocus end if list1.clear list1.additem 學(xué)號(hào) & - & 姓名 if rs.bof and rs.eof then else
26、 rs.movefirst do while rs.eof = false if len(rs!學(xué)號(hào)) = 1 then list1.additem 0 & rs!學(xué)號(hào) & - & rs!姓名 else list1.additem & rs!學(xué)號(hào) & - & rs!姓名 end if rs.movenext loop rs.movefirst end if list1.listindex = 1 display end sub private sub command8_click() rs.close list1.clear frame1.enabled = true frame2.enabl
27、ed = true command1.enabled = false command2.enabled = false command3.enabled = false command4.enabled = false command7.enabled = true command8.enabled = false command9.enabled = false command13.enabled = false for i = 0 to 8 txtcj(i).enabled = true txtcj(i).text = next i end sub private sub command9
28、_click() on error goto err for i = 0 to 8 if trim(txtcj(i).text) text3.text * 1 then msgbox 成績(jī)大于預(yù)定值!, , 成績(jī)第 & i + 1 & 項(xiàng)錯(cuò)誤 exit sub end if next i txtcj(9).text = txtcj(0) * 1 + txtcj(1) * 1 + txtcj(2) * 1 + txtcj(3) * 1 + txtcj(4) * 1 + txtcj(5) * 1 * (text2.text * 1) + txtcj(6) * 1 * (text2.text * 1
29、) + txtcj(7) * 1 * (text2.text * 1) + txtcj(8) * 1 * (text2.text * 1) if addflg = false then rs1.open select 語(yǔ)文,數(shù)學(xué),英語(yǔ),物理,化學(xué),政治,歷史,地理,生 物,總分 from 成績(jī)表 where 考試號(hào)= & trim(ksh.caption) & and 考試性質(zhì)= & text1.text & , con, adopenstatic, adlockpessimistic, adcmdtext rs1!語(yǔ)文 = trim(txtcj(0).text) rs1!數(shù)學(xué) = trim(
30、txtcj(1).text) rs1!英語(yǔ) = trim(txtcj(2).text) rs1!物理 = trim(txtcj(3).text) rs1!化學(xué) = trim(txtcj(4).text) rs1!政治 = trim(txtcj(5).text) * 1 * (text2.text * 1) rs1!歷史 = trim(txtcj(6).text) * 1 * (text2.text * 1) rs1!地理 = trim(txtcj(7).text) * 1 * (text2.text * 1) rs1!生物 = trim(txtcj(8).text) * 1 * (text2.
31、text * 1) rs1!總分 = trim(txtcj(9).text) rs1.updatebatch adaffectallchapters sbar1.panels.item(1) = 修改成功保存! rs1.close else cmdexe.activeconnection = con cmdexe.commandtext = insert into 成績(jī)表(考試號(hào),語(yǔ)文,數(shù) 學(xué),英語(yǔ),物理,化學(xué),政治,歷史,地理,生物,總分,考試性質(zhì)) values & ( & ksh.caption & , & txtcj(0).text & , & txtcj(1).text & , &
32、txtcj(2).text & , & txtcj(3).text & , & txtcj(4).text & , & txtcj(5).text * 1 * (text2.text * 1) & , & txtcj(6).text * 1 * (text2.text * 1) & , & txtcj(7).text * 1 * (text2.text * 1) & , & txtcj(8).text * 1 * (text2.text * 1) & , & txtcj(9).text & , & text1.text & ) cmdexe.execute sbar1.panels.item(
33、1) = 添加成功保存! icount = icount + 1 end if label3.caption = 共添加 & icount & 條記錄 rs.movenext if list1.listindex + 1 0 then combo1.listindex = 0 end if end sub private sub command1_click() rs.movefirst list1.listindex = 1 display end sub private sub command2_click() with rs .moveprevious if .bof then .mov
34、efirst else list1.listindex = list1.listindex - 1 end if end with display end sub private sub command3_click() with rs .movenext if rs.eof then rs.movelast else list1.listindex = list1.listindex + 1 end if end with display end sub private sub command4_click() rs.movelast list1.listindex = list1.list
35、count - 1 display end sub private sub list1_click() if list1.listindex -1 and combo3.listindex -1 then dim txtsql as string txtsql = select b.班級(jí),b.學(xué)號(hào),b.姓名,a.* from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where 姓 名 = & comlst(index).text & and 考試性質(zhì) = & combo3.text & adodc1.connectionstring = co
36、n.connectionstring adodc1.commandtype = adcmdtext adodc1.recordsource = txtsql adodc1.refresh set datagrid1.datasource = adodc1 end if end sub private sub form_load() call resizeinit(me) dim rsb as adodb.recordset set rsb = new adodb.recordset rsb.open select distinct b.班級(jí) as ksbj from 成績(jī)表 as a inne
37、r join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) , con, adopenstatic, , adcmdtext combo1.clear do while not rsb.eof combo1.additem rsb!ksbj rsb.movenext loop set rsx = new adodb.recordset rsx.open select distinct a.考試性質(zhì) as ksxz from 成績(jī) 表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) , con, adopenstatic, , adcmdtext com
38、bo3.clear do while not rsx.eof combo3.additem rsx!ksxz rsx.movenext loop if combo1.listcount 0 then combo1.listindex = 0 combo2.listindex = 9 end if if combo3.listcount 0 then combo3.listindex = 0 end if end sub private sub form_resize() call resizeform(me) 窗體改變時(shí),控件隨之變化 combo1.left = label1.left + l
39、abel1.width + 100 combo1.top = label1.top combo1.width = label1.width + 150 combo2.left = label3.left + label3.width + 100 combo2.top = label3.top combo2.width = label3.width + 150 combo3.left = label6.left + label6.width + 100 combo3.top = label6.top combo3.width = label6.width + 150 for i = 0 to 7
40、 comlst(i).top = label7.top comlst(i).left = txtfsd(i).left + i * 10 comlst(i).width = comlst(i).width next i end sub private sub txtfsd_keypress(index as integer, keyascii as integer) if not isnumeric(chr(keyascii) then keyascii = 0 end if end sub private sub execpass() for i = 0 to 7 if txtfsd(i).
41、text = then msgbox 分?jǐn)?shù)段數(shù)值錯(cuò)誤!此次統(tǒng)計(jì)不實(shí)。, , 錯(cuò) 誤項(xiàng) & i & : exit sub end if next i if cint(txtfsd(0).text) cint(txtfsd(1).text) and cint(txtfsd(1).text) cint(txtfsd(2).text) and cint(txtfsd(2).text) cint(txtfsd(3).text) and cint(txtfsd(3).text) cint(txtfsd(4).text) and cint(txtfsd(4).text) cint(txtfsd(5).tex
42、t) and cint(txtfsd(5).text) cint(txtfsd(6).text) and cint(txtfsd(6).text) cint(txtfsd(7).text) then else msgbox 請(qǐng)保持?jǐn)?shù)值遞減順序!此次統(tǒng)計(jì)不實(shí)。, , 數(shù) 值錯(cuò)誤: exit sub end if end sub private sub loaddata() dim query as string dim picrs as adodb.recordset set picrs = new adodb.recordset query = select b.姓名 as xm , a. &
43、 combo2.text & as cj from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b. 考試號(hào) where 班級(jí) = & combo1.text & and 考試性質(zhì) = & combo3.text & picrs.open query, con, adopenstatic, , adcmdtext with picrs do while not .eof if cint(picrs!cj) = cint(txtfsd(0).text) then icj(0) = icj(0) + 1 comlst(0).additem picrs!xm en
44、d if if cint(picrs!cj) = cint(txtfsd(1).text) and cint(picrs!cj) = cint(txtfsd(2).text) and cint(picrs!cj) = cint(txtfsd(3).text) and cint(picrs!cj) = cint(txtfsd(4).text) and cint(picrs!cj) = cint(txtfsd(5).text) and cint(picrs!cj) = cint(txtfsd(6).text) and cint(picrs!cj) = cint(txtfsd(7).text) an
45、d cint(picrs!cj) cint(txtfsd(6).text) then icj(7) = icj(7) + 1 comlst(7).additem picrs!xm end if .movenext loop end with label5.caption = picrs.recordcount for i = 0 to 7 txtcount(i).caption = icj(i) next i picrs.close end sub private sub dataout() for i = 0 to 7 icj(i) = 0 comlst(i).clear comlst(i)
46、.text = 請(qǐng)選 txtcount(i).caption = next i end sub 4.4.數(shù)據(jù)分析統(tǒng)計(jì)界面與代碼設(shè)計(jì)數(shù)據(jù)分析統(tǒng)計(jì)界面與代碼設(shè)計(jì): : 代碼分析代碼分析: : dim rscount as adodb.recordset dim cmdexec as adodb.command dim i as integer dim jwsf as string dim addflg as boolean private sub combo1_lostfocus() on error goto err dim ctl as control for each ctl in cont
47、rols if typeof ctl is textbox then ctl.text = 0 end if next ctl if combo1.listindex = -1 then exit sub else rscount.open select distinct a.考試性質(zhì) as ksxz from 成 績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where b.班級(jí) like & combo1.text, con, adopenstatic, , adcmdtext combo2.clear text1.text = combo2.t
48、ext = 請(qǐng)選擇性質(zhì) combo2.enabled = false if rscount.eof = false and rscount.bof = false then rscount.movefirst do while rscount.eof = false combo2.additem rscount!ksxz rscount.movenext combo2.enabled = true loop end if rscount.close end if exit sub err: call execerr(date, me.caption, err.number, err.sourc
49、e, err.description) end sub private sub command1_click() on error goto wrong if combo1.listindex = -1 or combo2.listindex = -1 or text1.text = then msgbox 統(tǒng)計(jì)需要項(xiàng)目未完整提供! exit sub end if if combo3.listindex = -1 and (combo3.text 否 and combo3.text 是) then msgbox 計(jì)外生情況描述不完整! exit sub else if combo3.text
50、= 否 then else end if end if txtzf(9).text = txtzf(9).text = txtzf(0).text * 1 + txtzf(1).text * 1 + txtzf(2).text * 1 + txtzf(3).text * 1 + txtzf(4).text * 1 + txtzf(5).text * 1 + txtzf(6).text * 1 + txtzf(7).text * 1 + txtzf(8).text * 1 if combo3.text = 否 then for i = 0 to 9 if txtzf(i).text 0 then
51、 rscount.open select count(*) as ywj from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where b.計(jì)外 = & combo3.text & and b.班級(jí) like & combo1.text & and a.考試性質(zhì) = & combo2.text & and a. & labxk(i). caption & = & txtzf(i).text * 0.6, con, adopenstatic, , adcmdtext txtzf(10 + i).text = rscount!ywj txtzf(
52、20 + i).text = rscount!ywj / text1.text * 100 rscount.close rscount.open select count(*) as ywy from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where b.計(jì)外 = & combo3.text & and b.班級(jí) like & combo1.text & and a.考試性質(zhì) = & combo2.text & and a. & labxk(i). caption & = & txtzf(i).text * 0.85, con, adope
53、nstatic, , adcmdtext txtzf(30 + i).text = rscount!ywy txtzf(40 + i).text = rscount!ywy / text1.text * 100 rscount.close rscount.open select sum( & labxk(i).caption & ) as ywz , count(*) as rs from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where b.計(jì)外 = & combo3.text & and b.班級(jí) like & combo1.text
54、& and a.考試性質(zhì) = & combo2.text & , con, adopenstatic, , adcmdtext txtzf(50 + i).text = rscount!ywz txtzf(60 + i).text = rscount!ywz / text1.text txtzf(70 + i).text = txtzf(20 + i).text * 0.4 + txtzf(40 + i).text * 0.2 + txtzf(60 + i).text * 0.4 txtzf(80 + i).text = rscount!rs rscount.close end if next
55、 i end if if combo3.text = 是 then for i = 0 to 9 if txtzf(i).text 0 then rscount.open select count(*) as ywj from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where b.班級(jí) like & combo1.text & and a.考試性質(zhì) = & combo2.text & and a. & labxk(i).caption & = & txtzf(i).text * 0.6, con, adopenstatic, , adcmd
56、text txtzf(10 + i).text = rscount!ywj txtzf(20 + i).text = rscount!ywj / text1.text * 100 rscount.close rscount.open select count(*) as ywy from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where b.班級(jí) like & combo1.text & and a.考試性質(zhì) = & combo2.text & and a. & labxk(i).caption & = & txtzf(i).text *
57、0.85, con, adopenstatic, , adcmdtext txtzf(30 + i).text = rscount!ywy txtzf(40 + i).text = rscount!ywy / text1.text * 100 rscount.close rscount.open select sum( & labxk(i).caption & ) as ywz , count(*) as rs from 成績(jī)表 as a inner join 學(xué)籍表 as b on a.考試號(hào) = b.考試號(hào) where b.班級(jí) like & combo1.text & and a.考試性
58、質(zhì) = & combo2.text & , con, adopenstatic, , adcmdtext txtzf(50 + i).text = rscount!ywz txtzf(60 + i).text = rscount!ywz / text1.text txtzf(70 + i).text = txtzf(20 + i).text * 0.4 + txtzf(40 + i).text * 0.2 + txtzf(60 + i).text * 0.4 txtzf(80 + i).text = rscount!rs rscount.close end if next i end if c
59、ommand3.enabled = true exit sub wrong: if err.number = 3705 then rscount.close msgbox 內(nèi)部錯(cuò)誤,請(qǐng)重新按一下“統(tǒng)計(jì)”按鈕! exit sub end if msgbox err.number & err.description & ,請(qǐng)檢查您的初始值 call execerr(date, me.caption, err.number, err.source, err.description) dim ctl as control for each ctl in controls if typeof ctl i
60、s textbox then ctl.text = 0 end if next ctl end sub private sub command2_click() unload me end sub private sub command3_click() on error goto err set cmdexec = new adodb.command cmdexec.activeconnection = con dim sqlstring as string for i = 0 to 9 if txtzf(i).text 0 then sqlstring = insert into 考核表(
溫馨提示
- 1. 本站所有資源如無(wú)特殊說(shuō)明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁(yè)內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒(méi)有圖紙預(yù)覽就沒(méi)有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫(kù)網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。
最新文檔
- 2024年信用貸款協(xié)議書示例文稿
- 2024年協(xié)議主體替換協(xié)議文件
- 獨(dú)家房產(chǎn)貸款居間服務(wù)協(xié)議電子
- 南京信息工程大學(xué)《自然地理學(xué)》2021-2022學(xué)年第一學(xué)期期末試卷
- 2024年產(chǎn)品銷售法定中文協(xié)議范本
- 代理記賬代辦合同模板
- 智能音箱的智能音質(zhì)與智慧家居考核試卷
- 橡膠制品的市場(chǎng)推廣與產(chǎn)品包裝考核試卷
- 2023年計(jì)量經(jīng)濟(jì)學(xué)實(shí)驗(yàn)心得體會(huì) (一)
- 儀器儀表制造業(yè)的企業(yè)戰(zhàn)略規(guī)劃與發(fā)展路徑考核試卷
- 中圖版七年級(jí)下冊(cè)信息技術(shù) 4.1策劃數(shù)字故事 教學(xué)設(shè)計(jì)
- 2024年全國(guó)職業(yè)院校技能大賽高職組(檢驗(yàn)檢疫技術(shù)賽項(xiàng))考試題庫(kù)(含答案)
- 和燈做朋友(教學(xué)設(shè)計(jì))-2023-2024學(xué)年五年級(jí)上冊(cè)綜合實(shí)踐活動(dòng)蒙滬版
- 樂(lè)理知識(shí)考試題庫(kù)130題(含答案)
- 人教版(2024)七年級(jí)地理上冊(cè)2.2《地形圖的判讀》精美課件
- 2024年共青團(tuán)入團(tuán)積極分子團(tuán)校結(jié)業(yè)考試試題庫(kù)及答案
- 2024年遼寧高考?xì)v史試題(含答案和解析)
- 黃河商品交易市場(chǎng)介紹稿
- Unit 3 My friends Part C Story time(教學(xué)設(shè)計(jì))-2024-2025學(xué)年人教PEP版英語(yǔ)四年級(jí)上冊(cè)
- 2024中國(guó)海油校園招聘2024人(高頻重點(diǎn)提升專題訓(xùn)練)共500題附帶答案詳解
- 孫中山誕辰紀(jì)念日主題班會(huì)主題班會(huì)
評(píng)論
0/150
提交評(píng)論