課程設(shè)計(jì)--- 圖書信息管理系統(tǒng)設(shè)計(jì)_第1頁
已閱讀1頁,還剩30頁未讀, 繼續(xù)免費(fèi)閱讀

下載本文檔

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

文檔簡介

1、<p><b>  管理信息系統(tǒng)</b></p><p><b>  課程設(shè)計(jì)</b></p><p>  課程名稱 管理信息系統(tǒng) </p><p>  設(shè)計(jì)題目 圖書信息管理系統(tǒng)設(shè)計(jì) </p>

2、;<p>  學(xué)生姓名 </p><p>  學(xué) 號 </p><p>  專業(yè)班級 <

3、;/p><p>  指導(dǎo)教師 </p><p>  設(shè)計(jì)時間 2011.6.13~6.18 </p><p><b>  摘要</b></p>&

4、lt;p>  隨著社會經(jīng)濟(jì)的發(fā)展,圖書信息管理已逐漸發(fā)展成為一門重要的學(xué)科,對圖書信息的管理高效與否已成為衡量一個部門是否信息化的重要標(biāo)志。此次設(shè)計(jì)的圖書信息管理系統(tǒng)包括圖書管理、圖書銷售、借閱管理、讀者信息管理以及系統(tǒng)用戶管理。系統(tǒng)的特點(diǎn)是操作方便,功能完備。</p><p>  本系統(tǒng)采用Visual FoxPro作為開發(fā)工具。通過此系統(tǒng)的開發(fā)可以使我們了解管理信息系統(tǒng)的需求分析、設(shè)計(jì)和實(shí)現(xiàn)的完整過程,

5、掌握數(shù)據(jù)庫的基本設(shè)計(jì)和管理方法,積累數(shù)據(jù)庫應(yīng)用系統(tǒng)實(shí)戰(zhàn)經(jīng)驗(yàn)。 </p><p><b>  關(guān)鍵詞:</b></p><p>  圖書信息管理系統(tǒng) VFP </p><p><b>  Abstract:</b></p><p>  As the social economy developed,

6、 the management of books information has become an important subject.The management efficiency for books information is an important symbol to measure whether a department is informationized. The design of the management

7、 system of book information include books management, book sales, lending management, reader information management and the users of the system management. The characteristics of the system is easy to operate and the fun

8、ction is complete.</p><p>  The system uses Visual FoxPro as a development tool. We can understand the needs of the management information system analysis, design and the complete process of implementation t

9、hrough the development of the system. We also have a koowledge of the basic design of the database and the management methods so as to accumulate actual combat experience of database application system.</p><p&

10、gt;  Key words:</p><p>  Management system of book information VFP</p><p><b>  目錄</b></p><p><b>  一、系統(tǒng)概述4</b></p><p><b>  1.設(shè)計(jì)目的4<

11、/b></p><p>  2.系統(tǒng)主要功能4</p><p><b>  二、系統(tǒng)分析4</b></p><p><b>  1.需求分析4</b></p><p><b>  2.可行性研究4</b></p><p>  3.業(yè)務(wù)流程分

12、析5</p><p>  4.數(shù)據(jù)流程分析5</p><p><b>  三、系統(tǒng)設(shè)計(jì)6</b></p><p>  1.系統(tǒng)總體結(jié)構(gòu)設(shè)計(jì)6</p><p>  2.數(shù)據(jù)結(jié)構(gòu)與數(shù)據(jù)庫設(shè)計(jì)7</p><p>  3.代碼及界面設(shè)計(jì)9</p><p><b&

13、gt;  4.輸出設(shè)計(jì)29</b></p><p><b>  四、結(jié)束語30</b></p><p><b>  五、參考文獻(xiàn)30</b></p><p>  六、指導(dǎo)教師意見及建議31</p><p><b>  一、系統(tǒng)概述</b></p>

14、<p><b>  1.設(shè)計(jì)目的</b></p><p>  課程設(shè)計(jì)是理論學(xué)習(xí)的補(bǔ)充環(huán)節(jié),是對我們所學(xué)知識的綜合運(yùn)用能力的檢驗(yàn),也是學(xué)生提高分析問題解決問題能力的大好實(shí)踐時機(jī)。通過課程設(shè)計(jì),讓我們接觸社會,深入實(shí)際,親自動手運(yùn)用所學(xué)的專業(yè)知識和技巧,去分析、研究、解決這些實(shí)際問題,從而靈活運(yùn)用所學(xué)知識,增強(qiáng)實(shí)際工作能力,為順利走向工作崗位打下堅(jiān)實(shí)的基礎(chǔ)。</p>

15、<p><b>  2.系統(tǒng)主要功能</b></p><p>  圖書信息管理系統(tǒng)主要包括登錄窗口、圖書入庫窗口、修改圖書信息窗口、銷售查詢窗口、圖書查詢窗口、圖書借還窗口、錄入讀者信息、修改圖書信息窗口、用戶注冊和密碼修改等,主要功能包括圖書管理、圖書銷售、讀者管理、圖書服務(wù)、系統(tǒng)管理,可以對圖書進(jìn)行入庫管理、銷售管理并能統(tǒng)計(jì)某段時間內(nèi)的利潤。</p><p

16、><b>  二、系統(tǒng)分析</b></p><p><b>  1.需求分析</b></p><p>  1)圖書管理。包括圖書入庫管理和修改圖書信息。</p><p>  2)圖書銷售??梢詫︿N售記錄進(jìn)行增刪改查操作。</p><p>  3)讀者管理。包括錄入讀者信息和修改讀者信息。<

17、;/p><p>  4)圖書服務(wù)。包括借閱圖書和圖書查詢。</p><p>  5)系統(tǒng)管理。用于管理系統(tǒng)用戶。</p><p><b>  2.可行性研究 </b></p><p>  本系統(tǒng)簡單實(shí)用,基本上人人會用,也不需花費(fèi)很大的物力和財(cái)力,只要一臺計(jì)算機(jī)即可實(shí)現(xiàn)。而且對圖書館或書店等部門都可使用。實(shí)現(xiàn)圖書管理的計(jì)算機(jī)

18、化,提高圖書管理的效率和規(guī)范化程度,節(jié)省了手工輸入帶來的麻煩。</p><p><b>  3.業(yè)務(wù)流程分析</b></p><p><b>  4.數(shù)據(jù)流程分析</b></p><p>  圖一 頂層數(shù)據(jù)流程圖</p><p>  圖二 第一層數(shù)據(jù)流程圖</p><p>

19、;<b>  三、系統(tǒng)設(shè)計(jì)</b></p><p><b>  系統(tǒng)總體結(jié)構(gòu)設(shè)計(jì)</b></p><p>  系統(tǒng)功能模塊示意圖 </p><p>  2.數(shù)據(jù)結(jié)構(gòu)與數(shù)據(jù)庫設(shè)計(jì)</p><p>  圖書信息管理系統(tǒng)主要用來對圖書進(jìn)行入庫登記、銷售管理,方便用戶查詢書目信息及借還圖書。該系統(tǒng)包含圖書信

20、息表(booksinfo.dbf)、圖書借閱信息表(lendinfo.dbf)、讀者信息表(readerinfo.dbf)、圖書銷售信息表(saleinfo.dbf)、密碼表(passwordinfo.dbf)。下面以表格形式來說明相關(guān)數(shù)據(jù)表的結(jié)構(gòu):</p><p>  表1 密碼表(passwordinfo.dbf)</p><p>  表1 圖書信息表(booksinfo.dbf)

21、</p><p>  表2 圖書借閱信息表(lendinfo.dbf)</p><p>  表3 讀者信息表(readerinfo.dbf)</p><p>  表4 圖書銷售信息表(saleinfo.dbf)</p><p><b>  3.代碼及界面設(shè)計(jì)</b></p><p>  1)

22、logo.scx(登陸界面)表單設(shè)計(jì)</p><p>  Command1(確定)的Click事件代碼:</p><p>  sele passwordinfo</p><p>  if allt(thisform.text1.value)==""</p><p>  thisform.text1.setfocus<

23、/p><p><b>  else</b></p><p>  if allt(thisform.text2.value)==""</p><p>  thisform.text2.setfocus</p><p><b>  else</b></p><p>

24、;  locate for allt(用戶名)=allt(thisform.text1.value);</p><p>  .and.allt(密碼)=allt(thisform.text2.value)</p><p><b>  if eof()</b></p><p>  messagebox("用戶名或密碼錯誤,請重新輸入!&

25、quot;,64,"提示")</p><p>  thisform.text1.value=""</p><p>  thisform.text2.value=""</p><p>  thisform.text1.setfocus()</p><p><b>  else

26、 </b></p><p>  cyonghu=allt(thisform.text1.value)</p><p>  cmima=allt(thisform.text2.value)</p><p>  do menu.mpr</p><p>  thisform.release</p><p><

27、;b>  endif</b></p><p><b>  endif</b></p><p><b>  endif</b></p><p>  Command2(退出)的Click事件代碼:</p><p>  thisform.release</p><p&

28、gt;  clea event</p><p><b>  quit</b></p><p>  2)tslr.scx表單設(shè)計(jì)</p><p>  Command1(確定)的Click事件代碼:</p><p>  use booksinfo</p><p>  if allt(thisform.

29、text1.value)==""</p><p>  messagebox("請輸入完整的必要信息!",64,"提示")</p><p>  thisform.text1.setfocus</p><p><b>  else</b></p><p>  if

30、allt(thisform.text2.value)==""</p><p>  messagebox("請輸入完整的必要信息!",64,"提示")</p><p>  thisform.text2.setfocus</p><p><b>  else</b></p>

31、<p>  if allt(thisform.text3.value)==""</p><p>  messagebox("請輸入完整的必要信息!",64,"提示")</p><p>  thisform.text3.setfocus</p><p><b>  else</b&g

32、t;</p><p>  if allt(thisform.text4.value)==""</p><p>  messagebox("請輸入完整的必要信息!",64,"提示")</p><p>  thisform.text4.setfocus</p><p><b>

33、  else</b></p><p>  if allt(thisform.text5.value)==""</p><p>  messagebox("請輸入完整的必要信息!",64,"提示")</p><p>  thisform.text5.setfocus</p><

34、p><b>  else</b></p><p>  if allt(thisform.text6.value)==""</p><p>  messagebox("請輸入完整的必要信息!",64,"提示")</p><p>  thisform.text6.setfocus&l

35、t;/p><p><b>  else</b></p><p>  if allt(thisform.text7.value)==""</p><p>  messagebox("請輸入完整的必要信息!",64,"提示")</p><p>  thisform.te

36、xt7.setfocus</p><p><b>  else</b></p><p>  append blank</p><p>  repl 書號 with allt(thisform.text1.value)</p><p>  repl 編號 with allt(thisform.text2.value)<

37、;/p><p>  repl 書名 with allt(thisform.text3.value)</p><p>  repl 作者 with allt(thisform.text4.value)</p><p>  repl 出版社 with allt(thisform.text5.value)</p><p>  repl 定價 with

38、allt(thisform.text6.value)</p><p>  repl 冊數(shù) with allt(thisform.text7.value)</p><p>  repl 備注 with allt(thisform.edit1.value)</p><p>  repl 入庫日期 with date()</p><p>  thi

39、sform.command2.click</p><p><b>  endif</b></p><p><b>  endif</b></p><p><b>  endif</b></p><p><b>  endif</b></p>

40、<p><b>  endif</b></p><p><b>  endif</b></p><p><b>  endif</b></p><p><b>  use</b></p><p>  Command2(重填)的Click事件代碼:

41、</p><p>  thisform.text1.value=""</p><p>  thisform.text2.value=""</p><p>  thisform.text3.value=""</p><p>  thisform.text4.value="&q

42、uot;</p><p>  thisform.text5.value=""</p><p>  thisform.text6.value=""</p><p>  thisform.text7.value=""</p><p>  thisform.edit1.value=&quo

43、t;"</p><p>  thisform.text1.setfocus</p><p>  Command3(返回)的Click事件代碼:</p><p>  thisform.release</p><p>  3)tsxg.scx表單設(shè)計(jì)</p><p>  Command3(第一條)的事件代碼Cli

44、ck按鈕:</p><p><b>  go top</b></p><p>  nhere=recno()</p><p>  thisform.label8.caption=allt(str(recno()))</p><p>  thisform.command4.enabled=.t.</p>&l

45、t;p>  thisform.command6.enabled=.t.</p><p>  thisform.init</p><p>  Command5(上一條)的Click事件代碼:</p><p><b>  skip -1</b></p><p><b>  if bof()</b>

46、</p><p>  this.enabled=.f.</p><p>  thisform.command3.enabled=.f.</p><p>  messagebox("已經(jīng)到第一條記錄了!",48,"提示")</p><p><b>  go top</b></p

47、><p>  nhere=recno()</p><p><b>  else</b></p><p>  thisform.init</p><p>  nhere=recno()</p><p><b>  endif</b></p><p>  th

48、isform.command4.enabled=.t.</p><p>  thisform.command6.enabled=.t.</p><p>  Command6(下一條)的Click事件代碼:</p><p><b>  skip -1</b></p><p><b>  if bof()</

49、b></p><p>  this.enabled=.f.</p><p>  thisform.command3.enabled=.f.</p><p>  messagebox("已經(jīng)到第一條記錄了!",48,"提示")</p><p><b>  go top</b>&

50、lt;/p><p>  nhere=recno()</p><p><b>  else</b></p><p>  thisform.init</p><p>  nhere=recno()</p><p><b>  endif</b></p><p>

51、;  thisform.command4.enabled=.t.</p><p>  thisform.command6.enabled=.t.</p><p>  Command4(最后一條)的Click事件代碼:</p><p><b>  go bottom</b></p><p>  nhere=recno()&

52、lt;/p><p>  thisform.label8.caption=allt(str(recno()))</p><p>  thisform.command3.enabled=.t.</p><p>  thisform.command5.enabled=.t.</p><p>  thisform.init</p><

53、p>  Command1(修改)的Click事件代碼:</p><p>  LPARAMETERS nButton, nShift, nXCoord, nYCoord</p><p>  Command2(刪除)的Click事件代碼:</p><p>  use booksinfo exclusive</p><p><b>

54、  go nhere</b></p><p>  mb=messagebox("確定要刪除嗎?",1+64,"提示")</p><p><b>  if mb==1</b></p><p><b>  delete</b></p><p><

55、b>  pack</b></p><p>  thisform.label11.init</p><p>  if nhere>num</p><p><b>  go bottom</b></p><p>  thisform.init</p><p><b>

56、  else</b></p><p><b>  go nhere</b></p><p>  thisform.init</p><p><b>  endif</b></p><p><b>  endif</b></p><p>  C

57、ommand8(返回)的Click事件代碼:</p><p>  thisform.release</p><p>  Commang7(快速定位)的Click事件代碼:</p><p>  sele booksinfo</p><p><b>  go top</b></p><p>  if

58、allt(thisform.text7.value)==""</p><p>  messagebox("請輸入要查詢的內(nèi)容!",64,"提示")</p><p>  thisform.text7.setfocus </p><p><b>  else</b></p>

59、<p>  locate for allt(書名)=allt(thisform.text7.value)</p><p><b>  if eof()</b></p><p><b>  go bottom</b></p><p>  thisform.init</p><p>  mes

60、sagebox("此書不存在,請重新輸入!",64,"提示")</p><p>  thisform.text7.setfocus</p><p><b>  else</b></p><p>  thisform.init</p><p><b>  endif<

61、/b></p><p>  nhere=recno()</p><p><b>  endif</b></p><p>  Lable11的Init代碼:</p><p>  count all to num</p><p>  thisform.label11.caption=allt(s

62、tr(num))</p><p><b>  go top</b></p><p>  4)tsxs.scx表單設(shè)計(jì)</p><p>  Optiongroup1(優(yōu)惠)的Click事件代碼:</p><p>  if this.option1.value=1</p><p>  thisform

63、.text7.value=allt(thisform.text5.value)</p><p>  this.option2.value=0</p><p>  this.option3.value=0</p><p>  this.option4.value=0</p><p><b>  endif</b></

64、p><p>  if this.option2.value=1</p><p>  thisform.text7.value=str(val(allt(thisform.text5.value))*0.9,7,2)</p><p>  this.option1.value=0</p><p>  this.option3.value=0</

65、p><p>  this.option4.value=0</p><p><b>  endif</b></p><p>  if this.option3.value=1</p><p>  thisform.text7.value=str(val(allt(thisform.text5.value))*0.8,7,2)&

66、lt;/p><p>  this.option1.value=0</p><p>  this.option2.value=0</p><p>  this.option4.value=0</p><p><b>  endif</b></p><p>  if this.option4.value=

67、1</p><p>  thisform.text7.value=str(val(allt(thisform.text5.value))*0.7,7,2)</p><p>  this.option1.value=0</p><p>  this.option2.value=0</p><p>  this.option3.value=0&l

68、t;/p><p><b>  endif</b></p><p>  Command1(確定)的Click事件代碼:</p><p>  if allt(thisform.text2.value)==""</p><p>  thisform.text1.setfocus</p><p

69、><b>  else</b></p><p>  thisform.list1.additem(allt(thisform.text2.value))</p><p>  thisform.list1.additem(" "+allt(thisform.text3.value))</p><p>  thisfor

70、m.list1.additem(" "+allt(thisform.text4.value))</p><p>  thisform.list1.additem("銷售價:"+allt(thisform.text7.value)+"元×"+allt(thisform.text6.value))</p><p>  th

71、isform.list1.additem("***********************")</p><p>  jiage=jiage+val(allt(thisform.text7.value))*val(allt(thisform.text6.value))</p><p>  thisform.label11.caption="價格總計(jì):"

72、+allt(str(jiage,7,2))+"元"</p><p>  sele saleinfo</p><p>  append blank</p><p>  repl 書號 with booksinfo.書號</p><p>  repl 書名 with allt(thisform.text2.value)<

73、/p><p>  repl 作者 with allt(thisform.text3.value)</p><p>  repl 出版社 with allt(thisform.text4.value)</p><p>  repl 定價 with val(allt(thisform.text5.value))</p><p>  repl 銷售價格

74、 with val(allt(thisform.text7.value))</p><p>  repl 銷售數(shù)量 with val(allt(thisform.text6.value))</p><p>  repl 標(biāo)識 with .T.</p><p>  repl 銷售日期 with date()</p><p>  thisform

75、.command2.click</p><p><b>  endif</b></p><p>  Command2(取消)的Click事件代碼:</p><p>  thisform.text1.value="ISBN "</p><p>  thisform.text1.setfocus</

76、p><p>  thisform.text2.value=""</p><p>  thisform.text3.value=""</p><p>  thisform.text4.value=""</p><p>  thisform.text5.value=""&

77、lt;/p><p>  thisform.text6.value=""</p><p>  thisform.text7.value=""</p><p>  thisform.optiongroup1.option1.value=1</p><p>  thisform.optiongroup1.opti

78、on2.value=0</p><p>  thisform.optiongroup1.option3.value=0</p><p>  thisform.optiongroup1.option4.value=0 </p><p>  Command3(打?。┑腃lick事件代碼:</p><p>  if !printstatus()&

79、lt;/p><p>  sele saleinfo</p><p>  report form xsqd.frx for 標(biāo)識=.t. to printer</p><p>  thisform.list1.clear</p><p>  thisform.label11.caption="價格總計(jì):"</p>

80、<p>  if allt(thisform.list1.value)==""</p><p>  locate for 標(biāo)識=.t.</p><p>  do while found()</p><p>  repl 標(biāo)識 with .f.</p><p><b>  continue</b&g

81、t;</p><p><b>  enddo</b></p><p><b>  endif</b></p><p><b>  else</b></p><p>  messagebox("打印機(jī)沒而準(zhǔn)備好!")</p><p>&

82、lt;b>  endif</b></p><p>  thisform.refresh</p><p>  Command4(返回)的Click事件代碼:</p><p>  thisform.release</p><p>  5)xscx..scx表單設(shè)計(jì)</p><p>  Command1(查

83、詢)的Click事件代碼:</p><p>  sele 書名,作者,出版社,銷售數(shù)量 from saleinfo into cursor salels;</p><p>  where 銷售日期>=ctod(thisform.combo1.value);</p><p>  .and.銷售日期<=ctod(thisform.combo2.value)

84、</p><p>  thisform.grid1.columncount=-1</p><p>  thisform.grid1.recordsource="salels"</p><p>  thisform.grid1.recordsourcetype=1</p><p>  Command2(統(tǒng)計(jì))的Click事件

85、代碼:</p><p>  if thisform.optiongroup1.option1.value==1</p><p>  sele 書名,作者,出版社,count(銷售數(shù)量) as 總銷售量 from salels into cursor tjls;</p><p>  group by 書名 order by 總銷售量 desc</p>&

86、lt;p>  thisform.grid1.columncount=-1</p><p>  thisform.grid1.recordsource="tjls"</p><p><b>  endif</b></p><p>  if thisform.optiongroup1.option2.value==1<

87、;/p><p>  sele 書名,作者,出版社,count(銷售數(shù)量) as 總銷售量 from salels into cursor tjls;</p><p>  group by 作者 order by 總銷售量 desc</p><p>  thisform.grid1.columncount=-1</p><p>  thisform

88、.grid1.recordsource="tjls"</p><p><b>  endif</b></p><p>  if thisform.optiongroup1.option3.value==1</p><p>  sele 書名,作者,出版社,count(銷售數(shù)量) as 總銷售量 from salels int

89、o cursor tjls;</p><p>  group by 出版社 order by 總銷售量 desc</p><p>  thisform.grid1.columncount=-1</p><p>  thisform.grid1.recordsource="tjls"</p><p><b>  e

90、ndif</b></p><p>  Command3(打?。┑腃lick事件代碼:</p><p>  if !printstatus()</p><p>  messagebox("請用A4紙!",16,"提示信息")</p><p>  report form xscx.frx to

91、printer</p><p>  thisform.refresh</p><p><b>  else</b></p><p>  messagebox("打印機(jī)沒有準(zhǔn)備好!",64,"提示")</p><p><b>  endif</b></p&

92、gt;<p>  Command4(打印預(yù)覽)的Click事件代碼:</p><p>  report form xscx.frx to preview in screen </p><p>  thisform.refresh</p><p>  Command5(退出)的Click事件代碼:</p><p>  thisfo

93、rm.release</p><p>  5)dzlr.scx表單設(shè)計(jì)</p><p>  注:代碼同tslr.scx表單代碼</p><p>  7)dzxg.scx表單設(shè)計(jì)</p><p>  注:代碼同tsxg.scx表單代碼</p><p>  8)tscx.scx表單設(shè)計(jì)</p><p&g

94、t;  Optiongroup1的Click事件代碼:</p><p>  if this.option1.value==1</p><p>  thisform.label2.caption="請輸入要查詢的書名:"</p><p><b>  endif</b></p><p>  if this

95、.option2.value==1</p><p>  thisform.label2.caption="請輸入要查詢的作者:"</p><p><b>  endif</b></p><p>  if this.option3.value==1</p><p>  thisform.label2.c

96、aption="請輸入要查詢的出版社:"</p><p><b>  endif</b></p><p>  Command1(確定)的Click事件代碼:</p><p>  sele readerinfo</p><p>  if allt(thisform.text3.value)=="

97、;"</p><p>  messagebox("請輸入你的編號!",64,"提示")</p><p>  thisform.text3.setfocus</p><p><b>  else</b></p><p>  locate for allt(讀者編號)=all

98、t(thisform.text3.value)</p><p><b>  if eof()</b></p><p>  messagebox("您還沒有注冊,請先注冊...",48,"警告")</p><p>  thisform.text3.value=""</p>

99、<p><b>  else</b></p><p>  sele lendinfo</p><p>  if thisform.optiongroup2.option2.value==1</p><p>  count for allt(讀者編號)=allt(thisform.text3.value);</p><

100、;p>  .and.allt(借閱情況)="預(yù)約" to cn</p><p><b>  go top</b></p><p><b>  if cn<3</b></p><p>  locate for allt(讀者編號)=allt(thisform.text3.value);<

101、/p><p>  .and.allt(書號)=allt(thisform.text2.value);</p><p>  .and.allt(借閱情況)="預(yù)約"</p><p><b>  if eof()</b></p><p>  append blank</p><p> 

102、 repl 書號 with allt(thisform.text2.value)</p><p>  repl 讀者編號 with allt(thisform.text3.value)</p><p>  repl 預(yù)約日期 with date()</p><p>  repl 借閱情況 with "預(yù)約"</p><p>

103、;<b>  else</b></p><p>  messagebox("您已經(jīng)預(yù)約此本書!",64,"提示")</p><p>  thisform.text2.value=""</p><p><b>  endif</b></p><p

104、><b>  else</b></p><p>  messagebox("最多只能預(yù)約3本圖書,您已經(jīng)預(yù)約3本了!",64,"提示")</p><p><b>  endif</b></p><p><b>  endif</b></p>

105、<p>  if thisform.optiongroup2.option1.value==1</p><p>  count for allt(讀者編號)=allt(thisform.text3.value);</p><p>  .and.allt(借閱情況)="借閱" to cn</p><p><b>  go top

106、</b></p><p><b>  if cn<3</b></p><p>  if thisform.check1.value==0</p><p>  append blank</p><p>  repl 書號 with allt(thisform.text2.value)</p>

107、<p>  repl 讀者編號 with allt(thisform.text3.value)</p><p>  repl 借閱日期 with date()</p><p>  repl 借閱情況 with "借閱"</p><p><b>  else</b></p><p>  lo

108、cate for allt(讀者編號)=allt(thisform.text3.value);</p><p>  .and.allt(書號)=allt(thisform.text2.value);</p><p>  .and.allt(借閱情況)="預(yù)約"</p><p><b>  if eof()</b></p

109、><p>  messagebox("您沒有預(yù)約此本圖書!",48,"警告")</p><p><b>  else</b></p><p>  repl 借閱日期 with date()</p><p>  repl 借閱情況 with "借閱"</p>

110、;<p><b>  endif</b></p><p><b>  endif</b></p><p><b>  else</b></p><p>  messagebox("最多只能借3本圖書,您已經(jīng)借了3本圖書!",64,"提示")<

111、/p><p><b>  endif</b></p><p><b>  endif </b></p><p><b>  endif</b></p><p><b>  endif</b></p><p>  Command2(取消

112、)的Click事件代碼:</p><p>  if allt(thisform.text3.value)==""</p><p>  messagebox("請輸入您的編號!",64,"提示")</p><p>  thisform.text3.setfocus</p><p>&l

113、t;b>  else</b></p><p>  sele readerinfo</p><p>  locate for allt(讀者編號)=allt(thisform.text3.value)</p><p><b>  if eof()</b></p><p>  messagebox(&quo

114、t;您還沒有注冊,請先注冊...",48,"警告")</p><p>  thisform.text3.value=""</p><p><b>  else</b></p><p>  sele lendinfo</p><p>  locate for allt(讀者

115、編號)=allt(thisform.text3.value);</p><p>  .and.allt(書號)=allt(thisform.text2.value);</p><p>  .and.allt(借閱情況)="預(yù)約"</p><p><b>  if eof()</b></p><p> 

116、 messagebox("您沒有預(yù)約此本書!",64,"提示")</p><p>  thisform.text2.value=""</p><p><b>  else</b></p><p><b>  delete</b></p><p&

117、gt;<b>  pack</b></p><p>  thisform.check1.value=0</p><p>  thisform.optiongroup2.option1.value=1</p><p>  thisform.optiongroup2.option1.value=0</p><p><b

118、>  endif</b></p><p><b>  endif</b></p><p><b>  endif</b></p><p>  Command3(第一條)的Click事件代碼:</p><p>  if allt(thisform.text1.value)==&quo

119、t;"</p><p>  sele booksinfo</p><p><b>  else</b></p><p>  sele booksls</p><p><b>  endif</b></p><p><b>  go top</b>

120、;</p><p>  thisform.init</p><p>  thisform.command4.enabled=.t.</p><p>  thisform.command6.enabled=.t.</p><p>  Command4(最后一條)的Click事件代碼:</p><p>  if allt(

121、thisform.text1.value)==""</p><p>  sele booksinfo</p><p><b>  else</b></p><p>  sele booksls</p><p><b>  endif</b></p><p>

122、;<b>  go bottom</b></p><p>  thisform.init</p><p>  thisform.command3.enabled=.t.</p><p>  thisform.command5.enabled=.t.</p><p>  Command5(上一條)的Click事件代碼:&l

123、t;/p><p>  if allt(thisform.text1.value)==""</p><p>  sele booksinfo</p><p><b>  else</b></p><p>  sele booksls</p><p><b>  endif&

124、lt;/b></p><p><b>  skip -1</b></p><p><b>  if bof()</b></p><p>  this.enabled=.f.</p><p>  thisform.command3.enabled=.f.</p><p>

125、  messagebox("已經(jīng)到第一條記錄了!",64,"提示")</p><p><b>  go top</b></p><p><b>  endif</b></p><p>  thisform.init</p><p>  thisform.com

126、mand4.enabled=.t.</p><p>  thisform.command6.enabled=.t.</p><p>  Command6(下一條)的Click事件代碼:</p><p>  if allt(thisform.text1.value)==""</p><p>  sele booksinfo&

127、lt;/p><p><b>  else</b></p><p>  sele booksls</p><p><b>  endif</b></p><p><b>  skip 1</b></p><p><b>  if eof()</

128、b></p><p>  this.enabled=.f.</p><p>  thisform.command4.enabled=.f.</p><p>  messagebox("已經(jīng)到最后一條記錄了!",64,"提示")</p><p><b>  go bottom</b&

129、gt;</p><p><b>  endif</b></p><p>  thisform.init</p><p>  thisform.command3.enabled=.t.</p><p>  thisform.command5.enabled=.t.</p><p>  Command

130、7(查詢)的Click事件代碼:</p><p>  sele booksinfo</p><p>  if allt(thisform.text1.value)==""</p><p>  messagebox("請輸入要查詢的內(nèi)容!",64,"提示")</p><p>  thi

131、sform.text1.setfocus</p><p><b>  else</b></p><p>  if thisform.optiongroup1.option1.value==1</p><p>  sele 書號,書名,作者,出版社 from booksinfo into cursor booksls;</p>&l

132、t;p>  where allt(書名)=allt(thisform.text1.value)</p><p><b>  endif</b></p><p>  if thisform.optiongroup1.option2.value==1</p><p>  sele 書號,書名,作者,出版社 from booksinfo int

133、o cursor booksls;</p><p>  where allt(作者)=allt(thisform.text1.value)</p><p><b>  endif</b></p><p>  if thisform.optiongroup1.option3.value==1</p><p>  sele

134、書號,書名,作者,出版社 from booksinfo into cursor booksls;</p><p>  where allt(出版社)=allt(thisform.text1.value)</p><p><b>  endif</b></p><p>  thisform.init</p><p><

135、;b>  endif</b></p><p>  Command8(返回)的Click事件代碼:</p><p>  thisform.release</p><p>  9)jhcx.scx表單設(shè)計(jì)</p><p>  Command1(查詢)的Click事件代碼:</p><p>  if all

136、t(thisform.text1.value)==""</p><p>  messagebox("請輸入讀者編號!",64,"提示")</p><p>  thisform.text1.setfocus</p><p><b>  else</b></p><p&

137、gt;  sele readerinfo</p><p>  locate for 讀者編號=allt(thisform.text1.value)</p><p><b>  if eof()</b></p><p>  messagebox("編號錯誤,請重新輸入!",64,"提示")</p>

溫馨提示

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

評論

0/150

提交評論