高校教工人事管理信息系統(tǒng)設計.doc_第1頁
高校教工人事管理信息系統(tǒng)設計.doc_第2頁
高校教工人事管理信息系統(tǒng)設計.doc_第3頁
高校教工人事管理信息系統(tǒng)設計.doc_第4頁
高校教工人事管理信息系統(tǒng)設計.doc_第5頁
已閱讀5頁,還剩25頁未讀 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領

文檔簡介

學 號課 程 設 計 報 告課程名稱 數(shù)據(jù)庫應用課程設計 題 目 高校人事管理信息系統(tǒng) 院 系 專 業(yè) 班 級 姓 名 指導教師 年月日課程設計評分表評分標準:1. 學生是否嚴格遵守課程設計紀律,按照規(guī)定時間完成設計任務(占30%)2. 程序設計的質(zhì)量與規(guī)范:(占40%)(1)是否采用了良好的設計方法,獨立完成程序設計(2)程序界面設計是否合理、美觀(3)數(shù)據(jù)庫設計是否合理,具有良好的擴展性(4)程序是否運行正常,未見運行錯誤3. 課程設計報告書的質(zhì)量與規(guī)范 (占30%)教師評分:1.學生出勤得分:(A) (B) (C) (D) 得分_2.程序設計得分:(A) (B) (C) (D) 得分_3.設計報告得分:(A) (B) (C) (D) 得分_ 總分:_教師評語: 根據(jù)該生在課程設計期間,是否嚴格遵守課程設計紀律,按照規(guī)定時間完成設計任務,完成的程序設計的質(zhì)量與規(guī)范,提交的課程設計報告書的質(zhì)量與規(guī)范等多方面的評分,該生本次課程設計的評分為:_ 教師簽名: 日期: 年 月 日設計題目高校人事管理信息系統(tǒng)設計主要內(nèi)容一、開發(fā)平臺 VB+ SQL SERVER 2000二、功能要求1、設計內(nèi)容設計一個高校教工人事管理信息系統(tǒng),該系統(tǒng)的用戶由一般用戶和管理員組成,不同的用戶擁有不同的權(quán)限,各自完成各自的管理功能。首先是歡迎界面,然后選擇登錄,登錄的時候首先要判斷用戶的身份,合法的用戶然后進入到系統(tǒng)主界面中,不同的用戶看到不同的系統(tǒng)功能。用sql server2000創(chuàng)建后臺數(shù)據(jù)庫,然后利用程序設計語言(VB)編寫程序?qū)崿F(xiàn)對數(shù)據(jù)庫的操作,按照要求完成所有的功能和模塊。2、高校教工人事管理信息系統(tǒng)主要功能(1)登錄界面、用戶注冊界面(2)用戶管理:用戶登記界面(添加、打印等操作)、用戶信息查詢界面(按照一定條件查詢)、修改密碼(刪除、修改)。(3)管理員管理:用戶基本信息界面(修改、刪除等操作)、工作時間界面、工資界面(修改)、年度考核界面。3、高校教工人事信息系統(tǒng)數(shù)據(jù)庫表單(表單和字段可以按照需求增、刪、改) (1)密碼表:工號、密碼、用戶身份(管理員和普通用戶)(2)基本信息表:工號、姓名、年齡、性別、職務、學歷、政治面貌、所屬部門(3)工作時間表:工號、姓名、來院時間、任職時間、工齡(4)工資表單:工號、姓名、基本工資、工齡補貼、獎金、實發(fā)工資(5)年度考核表:工號、考察年度、工作態(tài)度、工作業(yè)績 三、課程設計報告主要內(nèi)容 1 高校教工人事信息系統(tǒng)需求分析(給出系統(tǒng)的功能模塊圖,對各個功能作出詳細介紹) 2 高校教工人事信息系統(tǒng)界面設計(給出界面截圖及其主要控件的屬性設置表格) 3 高校教工人事信息系統(tǒng)數(shù)據(jù)庫設計(給出數(shù)據(jù)庫各個表單中數(shù)據(jù)的字段名,數(shù)據(jù)類型及其相應的說明) 4 高校教工人事管理信息系統(tǒng)程序設計(按照功能模塊給出詳細的程序代碼,并給出重點語句的注釋)1. 高校人事管理信息系統(tǒng)需求分析高校人事管理信息系統(tǒng)登 陸用 戶 登 陸管 理 員 登 陸用戶服務新用戶注冊管理員服務本用戶密碼的修改工資信息查詢年度考核信息查詢所有用戶密碼查詢所有用戶基本信息查詢所有用戶工作查詢查 詢 添 加 刪 除 添 加更 新 刪 除 添 加 更 新 刪 除所有用戶工資查詢所有用戶年度考核查詢圖1.1零件交易管理信息系統(tǒng)1.1歡迎界面1.1.1選中管理員登錄后便進入管理員登陸界面1.1.2選中用戶登陸后便進入用戶登陸界面1.2管理員界面 可以進行現(xiàn)有用戶的密碼信息管理,工作信息管理,工資信息管理,年度考察信息管理,基本信息管理。1.2.1密碼信息管理 利用VB界面,管理員可以查詢現(xiàn)有用戶密碼,修改信息,添加信息,刪除記錄,從而改變了數(shù)據(jù)庫中的信息。1.2.2工作信息管理 管理員可以查詢,修改,刪除,添加用戶的工作信息,在VB界面中修改了數(shù)據(jù)庫中的信息。1.2.3工資信息管理 管理員可以根據(jù)需要查詢,修改,刪除,添加用戶的工資信息,從而改變數(shù)據(jù)庫中的信息。1.2.3基本信息信息管理管理員可以根據(jù)需要查詢,修改,刪除,添加用戶的基本信息信息,從而改變數(shù)據(jù)庫中的信息。1.2.3年度考核信息管理管理員可以根據(jù)需要查詢,修改,刪除,添加用戶的年度考核信息,從而改變數(shù)據(jù)庫中的信息。1.3用戶界面 用戶可以進行本用戶密碼的修改,查看零件信息和工程項目使零件情況。1.3.1本用戶密碼修改用戶通過輸入和確認新密碼來更改自己的密碼。1.3.2工資信息信息查詢 用戶進入界面后可看到自己的工資信息。1.3.3年度考核信息查詢進入界面后用戶可看到自己的年度考核信息。2高校人事管理信息系統(tǒng)界面設計圖2.1 歡迎界面圖2.2 用戶登陸界面圖2.3 新用戶注冊界面 圖2.4 管理員登陸界面圖2.5 用戶服務界面表2.1 用戶服務界面屬性表對象屬性設定值SSTab1Caption密碼修改SSTab2Caption工資查詢SSTab3caption年度考核查詢Datagrid1datasourceAdodc1Adodc1commandtype2-adcmdtablerecordsource密碼表visiblefalsecaptionAdodc1Datagrid2datasourceAdodc2Adodc2commandtype2-adcmdtablerecordsource工資表visiblefalsecaptionAdodc2Datagrid3datasourceAdodc3Adodc3commandtype2-adcmdtablerecordsource年度考核表visiblefalsecaptionAdodc3圖2.6 管理員界面表2.2 管理員界面屬性表對象屬性設定值Option1Option2Command2caption后退Label2caption工號Label2caption姓名圖2.7 工號查詢界面圖2.8 姓名查詢界面圖2.9 管理員查詢界面表2.3 管理員查詢查詢界面屬性表對象屬性設置值Datagrid1datasourceAdodc1Adodc1commandtype2-adcmdtablerecordsource密碼表visiblefalsecaptionAdodc1Datagrid2datasourceAdodc2Adodc2commandtype2-adcmdtablerecordsource基本信息表visiblefalsecaptionAdodc2Datagrid3datasourceAdodc3Adodc3commandtype2-adcmdtablerecordsource工資表visiblefalsecaptionAdodc3Datagrid4atasourceAdodc4Adodc4commandtype2-adcmdtablerecordsource工作表visiblefalsecaptionAdodc4Datagrid5atasourceAdodc5Adodc5commandtype2-adcmdtablerecordsource年度考核表visiblefalsecaptionAdodc5SSTab1caption密碼信息SSTab2caption基本信息SSTab3caption工資信息SSTab4caption工作信息SSTab5caption考核信息3高校人事管理信息系統(tǒng)數(shù)據(jù)庫設計高校人事信息管理系統(tǒng)總共涉及5張表,分別是密碼表,基本信息表,工資表,工作表,年度考核表。表3.1密碼表字段名稱標始名稱數(shù)據(jù)類型是否允許為空字段說明工號編號char否主碼登錄密碼密碼char否身份身份Char是 表3.2基本信息表字段名稱標始名稱數(shù)據(jù)類型是否允許為空字段說明工號工號char否主碼姓名姓名char否性別性別char是年齡年齡tinyint是學歷學歷char是職務職務char是政治面貌政治面貌char是所屬部門政治面貌char是表3.3工資表字段名稱標始名稱數(shù)據(jù)類型是否允許為空字段說明工號工號char否主碼基本工資基本工資Money否工齡補貼工齡補貼Money是獎金獎金Money是實發(fā)工資實發(fā)工資Money是 表3.4工作況表字段名稱標始名稱數(shù)據(jù)類型是否允許為空字段說明工號工號char否主碼姓名姓名char是來院時間來院時間tinyint否任職時間任職時間tinyint是表3.5年度考核表字段名稱標始名稱數(shù)據(jù)類型是否允許為空字段說明工號工號char否主碼考察年度考察年度char是工作態(tài)度工作態(tài)度char是工作業(yè)績工作業(yè)績char是4高校人事管理信息系統(tǒng)程序設計(部分代碼)4.1歡迎界面歡迎界面是整個系統(tǒng)的首頁,進入此界面后,使用者可根據(jù)自己的身份選擇登陸方式。普通用戶選擇用戶登陸,管理員選擇管理員登陸。4.2用戶登陸和新用戶注冊界面程序設計普通用戶在此界面輸入自己的姓名和密碼通過驗證后方可進入下一個界面。部分重要代碼如下Private Sub Command2_Click()Dim strselectname As StringDim str As StringDim strselectpassword As StringDim strpassword As StringDim strselectuserlevel As StringDim ret_select As Booleanstrselectpassword = select 登錄密碼 from 密碼表 where 工號 = & & Trim(Text1.Text) & Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVstr = Trim(Text1.Text)strselectname = select 工號 from 密碼表 where 工號= & & str & Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.CommandType = adCmdTextAdodc1.RecordSource = strselectnameAdodc1.RefreshIf Adodc1.Recordset.EOF = True Then ret = MsgBox(工號錯誤!, 48, warming!) Text1.Text = Text2.Text = Exit Sub Else Adodc1.CommandType = adCmdTextAdodc1.RecordSource = strselectpasswordAdodc1.RefreshAdodc1.CommandType = adCmdTextAdodc1.RecordSource = strselectpasswordAdodc1.RefreshIf StrComp(Trim(Adodc1.Recordset.Fields(登錄密碼).Value), Trim(Text2.Text) 0 Then ret = MsgBox(密碼錯誤!, 48, warming!) Text2.Text = Text2.SetFocus Exit Sub Else MsgBox 登錄成功! AID = Text1.Text End If 用戶登錄.Hide 用戶服務.Show End IfEnd Sub進入用戶登錄界面后,新用戶還可以通過此界面進行注冊,新用戶只要輸入自己的姓名,注冊密碼并確認注冊便可以成功注冊,同時該用戶的信息也被寫入到了用戶信息表中(部分代碼如下)Private Sub Command1_Click()If Text1.Text = ThenMsgBox 請輸入你的工號Exit SubElseIf Text2.Text = ThenMsgBox 請輸入密碼Exit SubElseIf Text3.Text = ThenMsgBox 請再次輸入密碼Exit SubEnd IfAdodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.CommandType = adCmdTextAdodc1.RecordSource = select 工號 from 密碼表 where 工號 = & Trim(Text1.Text) & Adodc1.RefreshIf Adodc1.Recordset.EOF = False Then MsgBox 用戶名已經(jīng)存在!請重新輸入, 0, 提示 Text1.Text = Text2.Text = Text3.Text = Text1.SetFocus Exit SubEnd IfAdodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.CommandType = adCmdTableAdodc1.RecordSource = 密碼表Adodc1.RefreshAdodc1.Recordset.AddNewAdodc1.Recordset.Fields(工號).Value = Trim(Text1.Text)Adodc1.Recordset.Fields(登錄密碼).Value = Trim(Text2.Text)If Text3.Text = Then MsgBox 請再次輸入密碼 Text1.SetFocusExit SubElseIf Text2.Text Text3.Text ThenMsgBox 兩次輸入的密碼不一樣 Text3.Text = Exit SubEnd IfAdodc1.Recordset.UpdateMsgBox 恭喜你注冊成功 Text1.Text = Text2.Text = Text3.Text = 用戶注冊.Hide 用戶登錄.Show4.3管理員登陸界面管理員需要輸入自己的姓名和密碼,經(jīng)過系統(tǒng)驗證無誤后就可以進入下一個界面了。它的代碼與管理員登陸代碼類似,輸入的姓名和密碼必須是管理員表中相應的信息,否則就無法成功登陸。4.4用戶服務表界面用戶登陸進去后,可以到用戶服務界面選擇自己所需的服務,該界面為用戶提供了三種服務,分別是“本用戶密碼的修改”,“工資查詢”和“年度考核查詢”。4.5用戶密碼修改界面程序設計用戶如需修改自己的密碼可在此界面進行,用戶通過登陸界面登陸到此,然后在此界面中輸入原始密碼和新密碼并驗證新密碼,確認后如果無誤就會提示用戶修改成功,并且其密碼在用戶信息表中也會有相應的修改。(代碼如下)Private Sub Command1_Click() If Trim(Text2.Text) = Then MsgBox 對不起,輸入原密碼!, vbInformation Exit SubElseIf Trim(Text3.Text) = Then MsgBox 對不起,請輸入新密碼, vbInformation Exit SubElseIf Trim(Text4.Text) = Then MsgBox 對不起,請再次輸入新密碼, vbInformation Exit SubElseIf Trim(Text3.Text) Trim(Text4.Text) Then MsgBox 兩次輸入的密碼不一致! Text4.Text = Exit Sub End If Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.CommandType = adCmdTextAdodc1.RecordSource = select 登錄密碼 from 密碼表 where 登錄密碼 = & AID & Adodc1.RefreshIf Adodc1.Recordset.EOF = True Then MsgBox 密碼不正確,請重新輸入! Text2.Text = Text3.Text = Text4.Text = Text2.SetFocus Exit Sub Else Adodc1.Recordset.Fields(登錄密碼).Value = Trim(Text3.Text)Adodc1.Recordset.UpdateAdodc1.Refresh MsgBox 恭喜你,密碼修改成功! Text2.Text = Text3.Text = Text4.Text = End IfEnd Sub 4.6用戶服務界面用戶可通過此界面所提供的內(nèi)容查詢所有的零件信息。所有的信息通過控件DataGrid與Adodc控件和相應的數(shù)據(jù)庫連接起來,并通過sstab控件進行切換界面,設置相應的屬性后所有信息便可顯示在DataGrid上供用戶查看。圖4.1 零件信息的查詢界面 此控件要調(diào)用模塊,該代碼在load里面寫:Private Sub Form_Load()Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.CommandType = adCmdTextAdodc1.RecordSource = select * from 密碼表 where 密碼表.工號 = & AID & Adodc1.RefreshAdodc2.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc2.CommandType = adCmdTextAdodc2.RecordSource = select * from 年度考核表 left join 密碼表 on 密碼表.工號=年度考核表.工號 where 密碼表.工號 = & AID & Adodc2.RefreshAdodc3.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc3.CommandType = adCmdTextAdodc3.RecordSource = select * from 工資表 left join 密碼表 on 密碼表.工號=工資表.工號 where 密碼表.工號 = & AID & Adodc3.RefreshEnd Sub4.7管理員查詢界面該界面所用的控件與用戶服務界面所用的一樣,用戶想要查看的信息也會顯示在DataGrid上。圖4.2 管理員查詢界面Load里的代碼:Private Sub Form_Load() If 管理員界面.Option1 Then Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.CommandType = adCmdTextAdodc1.RecordSource = select * from 密碼表 where 密碼表.工號 = & AAA & Adodc1.RefreshAdodc2.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc2.CommandType = adCmdTextAdodc2.RecordSource = select * from 基本信息表 where 基本信息表.工號 = & AAA & Adodc2.RefreshAdodc3.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc3.CommandType = adCmdTextAdodc3.RecordSource = select * from 工資表 where 工資表.工號 = & AAA & Adodc3.RefreshAdodc4.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc4.CommandType = adCmdTextAdodc4.RecordSource = select * from 工作表 where 工作表.工號 = & AAA & Adodc4.RefreshAdodc5.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc5.CommandType = adCmdTextAdodc5.RecordSource = select * from 年度考核表 where 年度考核表.工號 = & AAA & Adodc5.RefreshElseAdodc2.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc2.CommandType = adCmdTextAdodc2.RecordSource = select * from 基本信息表 where 基本信息表.姓名 = & BBB & Adodc2.RefreshAdodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc1.CommandType = adCmdTextAdodc1.RecordSource = select * from 工作表 left join 密碼表 on 密碼表.工號=工作表.工號 where 工作表.姓名 = & BBB & Adodc1.RefreshAdodc3.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc3.CommandType = adCmdTextAdodc3.RecordSource = select * from 工作表 left join 工資表 on 工資表.工號=工作表.工號 where 工作表.姓名 = & BBB & Adodc3.RefreshAdodc4.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc4.CommandType = adCmdTextAdodc4.RecordSource = select * from 工作表 where 工作表.姓名 = & BBB & Adodc4.RefreshAdodc5.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC2009113022HNVAdodc5.CommandType = adCmdTextAdodc5.RecordSource = select * from 工作表 left join 年度考核表 on 年度考核表.工號=工作表.工號 where 工作表.姓名 = & BBB & Adodc5.Refresh End IfEnd Sub如想查詢所有,代碼如下:Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc1.CommandType = adCmdTextAdodc1.RecordSource = select * from 工資表 Adodc1.RefreshAdodc2.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc2.CommandType = adCmdTextAdodc2.RecordSource = select * from 工資表 Adodc2.RefreshAdodc3.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc3.CommandType = adCmdTextAdodc3.RecordSource = select * from 工資表 Adodc3.RefreshAdodc4.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc4.CommandType = adCmdTextAdodc4.RecordSource = select * from 工資表 Adodc4.RefreshAdodc5.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc5.CommandType = adCmdTextAdodc5.RecordSource = select * from 工資表 Adodc3.Refresh添加密碼代碼如下:Private Sub Command1_Click()Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc1.CommandType = adCmdTextAdodc1.RecordSource = select 工號 from 密碼表 where 工號 = & Trim(Text1.Text) & Adodc1.RefreshIf Adodc1.Recordset.EOF = False Then MsgBox 此工號已存在, 0, 提示 Exit SubEnd IfIf Text1.Text = Or Text2.Text = Or Text17.Text = ThenMsgBox 請將信息填寫完整ElseAdodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc1.CommandType = adCmdTableAdodc1.RecordSource = 密碼表Adodc1.RefreshAdodc1.Recordset.AddNewAdodc1.Recordset.Fields(工號).Value = Trim(Text1.Text)Adodc1.Recordset.Fields(登錄密碼).Value = Trim(Text2.Text)Adodc1.Recordset.Fields(身份).Value = Trim(Text17.Text)Adodc1.Recordset.UpdateMsgBox 恭喜你添加成功Text1.Text = Text2.Text = Text17.Text = Exit SubEnd IfEnd Sub添加用戶基本信息代碼如下:Private Sub Command1_Click()Adodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc1.CommandType = adCmdTextAdodc1.RecordSource = select 工號 from 密碼表 where 工號 = & Trim(Text1.Text) & Adodc1.RefreshIf Adodc1.Recordset.EOF = False Then MsgBox 此工號已存在, 0, 提示 Exit SubEnd IfIf Text1.Text = Or Text2.Text = Or Text17.Text = ThenMsgBox 請將信息填寫完整ElseAdodc1.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc1.CommandType = adCmdTableAdodc1.RecordSource = 密碼表Adodc1.RefreshAdodc1.Recordset.AddNewAdodc1.Recordset.Fields(工號).Value = Trim(Text1.Text)Adodc1.Recordset.Fields(登錄密碼).Value = Trim(Text2.Text)Adodc1.Recordset.Fields(身份).Value = Trim(Text17.Text)Adodc1.Recordset.UpdateMsgBox 恭喜你添加成功Text1.Text = Text2.Text = Text17.Text = Exit SubEnd IfEnd SubPrivate Sub Command10_Click()Adodc2.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc2.CommandType = adCmdTextAdodc2.RecordSource = select 工號 from 基本信息表 where 工號 = & Trim(Text3.Text) & Adodc2.RefreshIf Adodc2.Recordset.EOF = False Then MsgBox 此工號已存在, 0, 提示 Exit SubEnd IfIf Text3.Text = Or Text4.Text = Or Text5.Text = Or Text6.Text = Or Text7.Text = Or Text8.Text = Or Text9.Text = Or Text10.Text = ThenMsgBox 請將信息填寫完整ElseAdodc2.ConnectionString = Provider=SQLOLEDB.1;Integrated Security=SSPI;Persist Security Info=False;Initial Catalog=人事管理;Data Source=PC-043Adodc2.CommandType = adCmdTableAdodc2.RecordSource = 基本信息表Adodc2.RefreshAdodc2.Recordset.AddNewAdodc2.Recordset.Fields(工號).Value = Trim(Text3.Text)Adodc2.Recordset.Fields(性別).Value = Trim(Text4.Text)Adodc2.Recordset.Fields(學歷).Value

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論