⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 银行动态表.frm

📁 财务信息管理系统,适合做毕业论文的人使用
💻 FRM
📖 第 1 页 / 共 4 页
字号:
End Sub

'********************************************************************
'*函数说明: 初始化  Grid                                             *
'*参    数:                                                          *
'*                                                                   *
'*返回值  :                                                          *
'*********************************************************************
Public Sub initGrid()
   Dim i As Integer
   Dim rsHead As New UfRecordset, sqlHead As String
   sqlHead = "SELECT * FROM FD_Item WHERE iitems_id=2"
   Set rsHead = dbsZJ.OpenRecordset(sqlHead, dbOpenSnapshot)
   Label4 = rsHead!citems_name
   lblTime = Year(dSearchDate) & "年 " & Month(dSearchDate) & "月 " & Day(dSearchDate) & "日"
   
   With UfGridado1
      '设置表头
      .Rows = 0
      .Redraw = True
      .LargeVirtualGrid = True
      .Cols = 16
      .Rows = 2
      .FixedCols = 0
      .FixedRows = 2
      .TextMatrix(0, 0) = "账号"
      .TextMatrix(1, 0) = "账号"
      .JoinCells 0, 0, 1, 0, True
      
      .TextMatrix(0, 1) = "银行名称"
      .TextMatrix(1, 1) = "银行名称"
      .JoinCells 0, 1, 1, 1, True
      
      .TextMatrix(0, 2) = "币别"
      .TextMatrix(1, 2) = "币别"
      .JoinCells 0, 2, 1, 2, True
      
      .TextMatrix(0, 3) = "汇率"
      .TextMatrix(1, 3) = "汇率"
      .JoinCells 0, 3, 1, 3, True
      
      .TextMatrix(0, 4) = "上日余额"
      .TextMatrix(1, 4) = "上日余额"
      .JoinCells 0, 4, 1, 4, True
      
      .TextMatrix(0, 5) = "上日余额(本位币)"
      .TextMatrix(1, 5) = "上日余额(本位币)"
      .JoinCells 0, 5, 1, 5, True
      
      .TextMatrix(0, 6) = "本日收入额"
      .TextMatrix(1, 6) = "本日收入额"
      .JoinCells 0, 6, 1, 6, True
      
      .TextMatrix(0, 7) = "本日收入额(本位币)"
      .TextMatrix(1, 7) = "本日收入额(本位币)"
      .JoinCells 0, 7, 1, 7, True
      
      .TextMatrix(0, 8) = "笔数"
      .TextMatrix(1, 8) = "笔数"
      .JoinCells 0, 8, 1, 8, True
      
      .TextMatrix(0, 9) = "本日支出额"
      .TextMatrix(1, 9) = "本日支出额"
      .JoinCells 0, 9, 1, 9, True
      
      .TextMatrix(0, 10) = "本日支出额(本位币)"
      .TextMatrix(1, 10) = "本日支出额(本位币)"
      .JoinCells 0, 10, 1, 10, True
      
      .TextMatrix(0, 11) = "笔数"
      .TextMatrix(1, 11) = "笔数"
      .JoinCells 0, 11, 1, 11, True
      
      .TextMatrix(0, 12) = "本日余额"
      .TextMatrix(1, 12) = "本日余额"
      .JoinCells 0, 12, 1, 12, True
      
      .TextMatrix(0, 13) = "本日余额(本位币)"
      .TextMatrix(1, 13) = "本日余额(本位币)"
      .JoinCells 0, 13, 1, 13, True
      
      .TextMatrix(0, 14) = "净收/支"
      .TextMatrix(1, 14) = "净收/支"
      .JoinCells 0, 14, 1, 14, True
      
      .TextMatrix(0, 15) = "净收/支(本位币)"
      .TextMatrix(1, 15) = "净收/支(本位币)"
      .JoinCells 0, 15, 1, 15, True
      
      ' 设置宽度
      For i = 0 To 15
          Select Case i
              Case 0
                  .ColWidth(i) = 1200
              Case 1
                  .ColWidth(i) = 2000
              Case 2, 3
                  .ColWidth(i) = 650
              Case 4, 5, 6, 7, 9, 10, 12, 13, 14, 15
                  .ColWidth(i) = 2000
              Case 8, 11
                  .ColWidth(i) = 330
          End Select
      Next i
   
      '设置表体的Alignment
      For i = 0 To 15
          Select Case i
              Case 1
                  .ColAlignment(i) = UG_ALIGNLEFT
              Case 0, 2, 8, 11
                  .ColAlignment(i) = UG_ALIGNCENTER
              Case 3, 4, 5, 6, 7, 9, 10, 12, 13, 14, 15
                  .ColAlignment(i) = UG_ALIGNRIGHT
          End Select
      Next i
      
      .HeadFont.Name = "宋体"
      .HeadFont.Size = 9
      .HeadBackColor = &H8000000E
      .HeadFont.Bold = True
   End With
   Set frmRptItem.mCollectColWidth = New Collection
   For i = 0 To 15
      frmRptItem.mCollectColWidth.Add UfGridado1.ColWidth(i), CStr(i)
   Next i
   
End Sub

Private Sub ChangeStatus(cItemName As String, iChangeUnit As Long, Optional bVisible As Boolean)
   StatusBar1.Panels(2).Text = cItemName
   ProBar1.Value = ProBar1.Value + iChangeUnit
   DoEvents
   
End Sub

Private Sub DoUnload(blnLoad As Boolean)
   DoUnloadInfo.blnRyhdt = blnLoad
End Sub

Private Sub Form_QueryUnload(Cancel As Integer, UnloadMode As Integer)
   Cancel = DoUnloadInfo.blnRyhdt
End Sub

Private Sub Form_Resize()
   On Error Resume Next
   If Me.WindowState <> 1 Then
      If Me.Width < frmMinWidth Then Me.Width = frmMinWidth
      If Me.Height < frmMinWidth Then Me.Height = frmMinWidth
      UfGridado1.Width = Me.Width - 100
      UfGridado1.Height = Me.Height - Toolbar1.Height - Picture1.Height - 400 - IIf(StatusBar1.Visible, StatusBar1.Height, 0)
      UfGridado1.Top = Toolbar1.Height + Picture1.Height
      UfGridado1.Left = 0
      Picture1.Left = Me.Width - Picture1.Width
      Label4.Left = Me.Width / 2 - Label4.Width / 2 + (Picture1.Width - Me.Width)
      lblTime.Left = Me.Width - lblTime.Width - 200 + (Picture1.Width - Me.Width)
      ProBar1.Left = 4860
      ProBar1.Top = Me.Height - 640
   End If
   On Error GoTo 0
End Sub

Private Sub Form_Unload(Cancel As Integer)
   Dim i As Long
   For i = 1 To 4
      preDayYe(i) = 0
      toDayYe(i) = 0
      toDaySr(i) = 0
      toDayZc(i) = 0
      toDayJsz(i) = 0
      toDayBsr(i) = 0
      toDayBzc(i) = 0
   Next i
    zjLogInfo.TaskExec "FD0404", 0, zjLogInfo.cIYear
    zjLogInfo.ClearError
    zjGen_arr.FD0404 = False
End Sub

Private Sub Recx()
   With frmReportXz
      .Quitfs = False
      .strReportType = "Yhdt"
      .Show vbModal
   End With
End Sub

Private Sub Toolbar1_ButtonClick(ByVal Button As ComctlLib.Button)
   Gen_Key Button.key
End Sub

Private Sub InitDataOut()
   ReDim prnReport1(16)
   
   prnReport1(0).iColNumber = 0
   prnReport1(0).iColType = dbText
   prnReport1(0).cColName = UfGridado1.TextMatrix(0, 0)
   prnReport1(0).iColLength = lngText
   
   prnReport1(1).iColNumber = 1
   prnReport1(1).iColType = dbText
   prnReport1(1).cColName = UfGridado1.TextMatrix(0, 1)
   prnReport1(1).iColLength = lngText
   
   prnReport1(2).iColNumber = 2
   prnReport1(2).iColType = dbText
   prnReport1(2).cColName = UfGridado1.TextMatrix(0, 2)
   prnReport1(2).iColLength = lngText
   
   prnReport1(3).iColNumber = 3
   prnReport1(3).iColType = dbCurrency
   prnReport1(3).cColName = UfGridado1.TextMatrix(0, 3)
   prnReport1(3).iColLength = lngCurrency
   
   prnReport1(4).iColNumber = 4
   prnReport1(4).iColType = dbCurrency
   prnReport1(4).cColName = UfGridado1.TextMatrix(0, 4)
   prnReport1(4).iColLength = lngCurrency
   
   prnReport1(5).iColNumber = 5
   prnReport1(5).iColType = dbCurrency
   prnReport1(5).cColName = UfGridado1.TextMatrix(0, 5)
   prnReport1(5).iColLength = lngCurrency
   
   prnReport1(6).iColNumber = 6
   prnReport1(6).iColType = dbCurrency
   prnReport1(6).cColName = UfGridado1.TextMatrix(0, 6)
   prnReport1(6).iColLength = lngCurrency
   
   prnReport1(7).iColNumber = 7
   prnReport1(7).iColType = dbCurrency
   prnReport1(7).cColName = UfGridado1.TextMatrix(0, 7)
   prnReport1(7).iColLength = lngCurrency
   
   prnReport1(8).iColNumber = 8
   prnReport1(8).iColType = dbLong
   prnReport1(8).cColName = UfGridado1.TextMatrix(0, 8)
   prnReport1(8).iColLength = lngText
   
   prnReport1(9).iColNumber = 9
   prnReport1(9).iColType = dbCurrency
   prnReport1(9).cColName = UfGridado1.TextMatrix(0, 9)
   prnReport1(9).iColLength = lngCurrency
   
   prnReport1(10).iColNumber = 10
   prnReport1(10).iColType = dbCurrency
   prnReport1(10).cColName = UfGridado1.TextMatrix(0, 10)
   prnReport1(10).iColLength = lngCurrency
   
   prnReport1(11).iColNumber = 11
   prnReport1(11).iColType = dbLong
   prnReport1(11).cColName = UfGridado1.TextMatrix(0, 11)
   prnReport1(11).iColLength = lngText
   
   prnReport1(12).iColNumber = 12
   prnReport1(12).iColType = dbCurrency
   prnReport1(12).cColName = UfGridado1.TextMatrix(0, 12)
   prnReport1(12).iColLength = lngCurrency

   prnReport1(13).iColNumber = 13
   prnReport1(13).iColType = dbCurrency
   prnReport1(13).cColName = UfGridado1.TextMatrix(0, 13)
   prnReport1(13).iColLength = lngCurrency

   prnReport1(14).iColNumber = 14
   prnReport1(14).iColType = dbCurrency
   prnReport1(14).cColName = UfGridado1.TextMatrix(0, 14)
   prnReport1(14).iColLength = lngCurrency

   prnReport1(15).iColNumber = 15
   prnReport1(15).iColType = dbCurrency
   prnReport1(15).cColName = UfGridado1.TextMatrix(0, 15)
   prnReport1(15).iColLength = lngCurrency
End Sub

Private Sub Gen_Key(TLB_Key As String)
    '----设置互斥
    If m_bExclude = True Then Exit Sub
   
    Select Case TLB_Key
        Case Is = "Print", "Preview", "Dataout"
            If TLB_Key = "Dataout" Then InitDataOut
            zjbPrnViewOut Me, "yhdtb", TLB_Key, True, Label4.Caption, "", "", lblTime.Caption
      Case "Recx"
         Recx
      Case "Item"
         With frmRptItem
            Set .mGrid = Me.UfGridado1
            .mStartCol = 2
            .mEndCol = 15
            .Show vbModal
         End With
      Case "Help"
         SendKeys "{F1}"
      Case "Exit"
         Unload Me
   End Select
   
End Sub

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -