个人收支管理程序

上传人:第*** 文档编号:33859050 上传时间:2018-02-18 格式:DOCX 页数:9 大小:18.01KB
返回 下载 相关 举报
个人收支管理程序_第1页
第1页 / 共9页
个人收支管理程序_第2页
第2页 / 共9页
个人收支管理程序_第3页
第3页 / 共9页
个人收支管理程序_第4页
第4页 / 共9页
个人收支管理程序_第5页
第5页 / 共9页
点击查看更多>>
资源描述

《个人收支管理程序》由会员分享,可在线阅读,更多相关《个人收支管理程序(9页珍藏版)》请在金锄头文库上搜索。

1、F1Dim n As Integer, j As String: Public mm As StringPrivate Sub cmdOK_Click()Select Case txtmima.TextCase mmForm1.Hide: Form2.ShowCase Is mmi = MsgBox(密码错误,重试, 16, 错误)n = n + 1End SelectIf n = 3 ThenUnload Form1End IfEnd SubPrivate Sub cmdNo_Click()EndEnd SubPrivate Sub Form_Load()If Dir(balance.pas

2、t) = ThenExit SubElse: Dim b As LongOpen App.Path & balance.pas For Binary As #1Get #1, 1, bClosemm = bEnd IfEnd SubF2Private Sub cmdBill_Click()Form2.Hide: Form4.ShowEnd SubPrivate Sub cmdCount_Click()Form2.Hide: Form5.ShowEnd SubPrivate Sub cmdSet_Click()Form2.Hide: Form3.ShowEnd SubPrivate Sub cm

3、dOut_Click()EndEnd SubF3Private Sub cmdAdd1_Click()Dim NamIn As String, n As Integer: NamIn = txtIn.TextIf NamIn = Then Exit SubFor n = 0 To lstIn.ListCount - 1If NamIn = lstIn.List(n) ThenExit SubEnd IfNextlstIn.AddItem NamInNamIn = End SubPrivate Sub cmdAdd2_Click()Dim NamOut As String, n As Integ

4、er: NamOut = txtOut.TextIf NamOut = Then Exit SubFor n = 0 To lstOut.ListCount - 1If NamOut = lstOut.List(n) ThenExit SubEnd IfNextlstOut.AddItem NamOutNamOut = End SubPrivate Sub cmdChange1_Click()lstIn.List(lstIn.ListIndex) = txtIn.TextlstIn.ListIndex = -1txtIn.Text = End SubPrivate Sub cmdChange2

5、_Click()lstOut.List(lstOut.ListIndex) = txtOut.TextlstOut.ListIndex = -1txtOut.Text = End SubPrivate Sub cmdClear1_Click()If lstIn.ListIndex -1 ThenlstIn.RemoveItem lstIn.ListIndextxtIn.Text = Else: Exit SubEnd IfEnd SubPrivate Sub cmdClear2_Click()If lstOut.ListIndex -1 ThenlstOut.RemoveItem lstOut

6、.ListIndextxtOut.Text = Else: Exit SubEnd IfEnd SubPrivate Sub cmdQuit1_Click()txtIn.Text = End SubPrivate Sub cmdQuit2_Click()txtOut.Text = End SubPrivate Sub cmdReturn1_Click()Unload Form3: Form2.ShowEnd SubPrivate Sub cmdReturn2_Click()Unload Form3: Form2.ShowEnd SubPrivate Sub Command14_Click()t

7、xtxinmima1.Text = : txtxinmima2.Text = End SubPrivate Sub Command15_Click()Form2.Show: Form3.HideEnd SubPrivate Sub Command13_Click()If IsNumeric(txtxinmima1.Text) = False Theni = MsgBox(密码应为数字, 16, 注意)ElseIf Len(txtxinmima1.Text) 8 Theni = MsgBox(注意密码位数, 16, 注意)ElseIf IsNumeric(txtxinmima1.Text) =

8、True ThenIf txtxinmima2.Text = txtxinmima1.Text ThenDim b As Long: b = txtxinmima1.TextOpen App.Path & balance.pas For Binary As #1Put #1, 1, bClosei = MsgBox(修改成功, 64, )Else: i = MsgBox(密码不一致,请重新输入! , 16, 注意)End IfEnd IfEnd SubPrivate Sub Command2_Click()Unload Form3: Form2.ShowEnd SubPrivate Sub F

9、orm_Unload(Cancel As Integer)Dim i As IntegerOpen App.Path & Inputtype.TXT For Output As #1For i = 0 To lstIn.ListCount - 1Write #1, lstIn.List(i)NextOpen App.Path & Outputtype.TXT For Output As #2For i = 0 To lstOut.ListCount - 1Write #2, lstOut.List(i)NextClose #1, #2End SubPrivate Sub lstIn_Click

10、()If lstIn.ListIndex -1 ThentxtIn.Text = lstIn.List(lstIn.ListIndex)Else: Exit SubEnd IfEnd SubPrivate Sub lstOut_Click()If lstOut.ListIndex -1 ThentxtOut.Text = lstOut.List(lstOut.ListIndex)Else: Exit SubEnd IfEnd SubF4Private Sub cmdClear1_Click()txtNumin.Text = : txtBeizhuIn.Text = : cboIn.Text =

11、 End SubPrivate Sub cmdClear2_Click()txtNumOut.Text = : txtBeizhuOut = : cboOut.Text = End SubPrivate Sub cmdKeep_Click()i = MsgBox(核对无误,确认保存, 32, 注意)lstInBill.AddItem DTPIn.Value & Space(5) & cboIn.Text & Space(12) & txtNumin.Text & Space(10) & txtBeizhuInOpen App.Path & Balance.TXT For Append As #

12、2Print #2, 1; DTPIn.Value, cboIn.Text, txtNumin.Text, txtBeizhuInClose 2lstInBill.List(lstInBill.ListCount - 1) = lstInBill.List(lstInBill.NewIndex)End SubPrivate Sub cmdKeep2_Click()i = MsgBox(核对无误,确认保存, 32, 注意)lstOutBill.AddItem DTPout.Value & Space(5) & cboOut.Text & Space(8) & txtNumOut.Text & S

13、pace(10) & txtBeizhuOutOpen App.Path & Balance.TXT For Append As #3Print #3, 0; DTPout.Value, cboOut.Text, txtNumOut.Text, txtBeizhuOutClose 3lstOutBill.List(lstOutBill.ListCount - 1) = lstOutBill.List(lstOutBill.NewIndex)End SubPrivate Sub cmdReturn3_Click()Form4.Hide: Form2.ShowEnd SubPrivate Sub

14、Form_Load()lstInBill.Text = : lstOutBill.Text = Dim a() As StringDim i As IntegerOpen App.Path & Inputtype.TXT For Input As #1Do While Not EOF(1)i = i + 1ReDim Preserve a(1 To i)Input #1, a(i)cboIn.AddItem a(i)LoopOpen App.Path & Outputtype.TXT For Input As #2Do While Not EOF(2)i = i + 1ReDim Preser

15、ve a(1 To i)Input #2, a(i)cboOut.AddItem a(i)LoopClose #2, #1End SubPrivate Sub Form_Unload(Cancel As Integer)txtNumin.Text = : txtBeizhuIn = : cboIn.Text = : lstInBill.CleartxtNumOut.Text = : txtBeizhuOut = : cboOut.Text = : lstOutBill.ClearEnd SubF5Private Sub cmdNo_Click()optTime.Value = False: o

16、ptKind.Value = False: cbokind1.Text = Frame2.Caption = 按类型查询: Label1.Visible = True: Label2.Visible = TrueDTPIn1.Visible = True: DTPIn2.Visible = TrueLabel3.Visible = True: cbokind1.Visible = TrueEnd SubPrivate Sub cmdNo2_Click()optTime2.Value = False: optKind2.Value = False: cboKind2.Text = Frame4.Caption = 按时间查询: Label5.Visible = Tru

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 学术论文 > 毕业论文

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号