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

📄 对帐单.frm

📁 财务信息管理系统,适合做毕业论文的人使用
💻 FRM
📖 第 1 页 / 共 5 页
字号:
      
      '初始化表头及对齐方式
        .TextMatrix(0, 0) = "日期"
        .TextMatrix(0, 1) = "日期"
        .TextMatrix(0, 2) = "日期"
        .JoinCells 0, 0, 0, 2, True
        .ColAlignment(0) = UG_ALIGNCENTER
        
        .TextMatrix(1, 0) = "年"
        .TextMatrix(1, 1) = "月"
        .TextMatrix(1, 2) = "日"
      
      .TextMatrix(0, 5) = "摘要"
      .JoinCells 0, 5, 1, 5, True
      .ColAlignment(5) = UG_ALIGNLEFT
      
      If iDataSource = 1 Then
         .TextMatrix(0, 3) = "凭证号"
         .JoinCells 0, 3, 1, 3, True
         .ColAlignment(3) = UG_ALIGNCENTER
         .ColWidth(3) = 1000
         
         .TextMatrix(0, 4) = "业务ID"
         .JoinCells 0, 4, 1, 4, True
         .ColAlignment(4) = UG_ALIGNRIGHT
         'cuidong 对账单+外币 2001.12.04
         '---------------------------------------
'         .TextMatrix(0, 5) = "借方"
'         .JoinCells 0, 5, 1, 5, True
'         .ColAlignment(5) = UG_ALIGNRIGHT
'
'         .TextMatrix(0, 6) = "贷方"
'         .JoinCells 0, 6, 1, 6, True
'         .ColAlignment(6) = UG_ALIGNRIGHT
'
'         .TextMatrix(0, 7) = "借或贷"
'         .JoinCells 0, 7, 1, 7, True
'         .ColWidth(7) = 600
'         .ColAlignment(7) = UG_ALIGNCENTER
'
'         .TextMatrix(0, 8) = "余额"
'         .JoinCells 0, 8, 1, 8, True
'         .ColAlignment(8) = UG_ALIGNRIGHT
'         .ColWidth(8) = 1800
         
         .TextMatrix(0, 6) = "借方"
         .JoinCells 0, 6, 1, 6, True
         .ColAlignment(6) = UG_ALIGNRIGHT
         
         .TextMatrix(0, 7) = "借方(外币)"
         .JoinCells 0, 7, 1, 7, True
         .ColAlignment(7) = UG_ALIGNRIGHT
          
         .TextMatrix(0, 8) = "贷方"
         .JoinCells 0, 8, 1, 8, True
         .ColAlignment(8) = UG_ALIGNRIGHT
         
         .TextMatrix(0, 9) = "贷方(外币)"
         .JoinCells 0, 9, 1, 9, True
         .ColAlignment(9) = UG_ALIGNRIGHT
         
         .TextMatrix(0, 10) = "借或贷"
         .JoinCells 0, 10, 1, 10, True
         .ColWidth(10) = 600
         .ColAlignment(10) = UG_ALIGNCENTER
         
         .TextMatrix(0, 11) = "余额"
         .JoinCells 0, 11, 1, 11, True
         .ColAlignment(11) = UG_ALIGNRIGHT
         .ColWidth(11) = 1800
      
         .TextMatrix(0, 12) = "余额(外币)"
         .JoinCells 0, 12, 1, 12, True
         .ColAlignment(12) = UG_ALIGNRIGHT
         .ColWidth(12) = 1800
         '---------------------------------------
         
      Else
         
         .TextMatrix(0, 3) = "业务编号"
         .JoinCells 0, 3, 1, 3, True
         .ColAlignment(3) = UG_ALIGNRIGHT
         
         .TextMatrix(0, 4) = "业务ID"
         .JoinCells 0, 4, 1, 4, True
         .ColAlignment(4) = UG_ALIGNRIGHT
         
         'cuidong 对账单+外币 2001.12.04
         '---------------------------------------
'         .TextMatrix(0, 5) = "收入额"
'         .JoinCells 0, 5, 1, 5, True
'         .ColAlignment(5) = UG_ALIGNRIGHT
'
'         .TextMatrix(0, 6) = "支出额"
'         .JoinCells 0, 6, 1, 6, True
'         .ColAlignment(6) = UG_ALIGNRIGHT
'
'         .TextMatrix(0, 7) = "余额"
'         .JoinCells 0, 7, 1, 7, True
'         .ColAlignment(7) = UG_ALIGNRIGHT
'         .ColWidth(7) = 1800
         
         .TextMatrix(0, 6) = "收入额"
         .JoinCells 0, 6, 1, 6, True
         .ColAlignment(6) = UG_ALIGNRIGHT
         
         .TextMatrix(0, 7) = "收入额(本位币)"
         .JoinCells 0, 7, 1, 7, True
         .ColAlignment(7) = UG_ALIGNRIGHT
         
         .TextMatrix(0, 8) = "支出额"
         .JoinCells 0, 8, 1, 8, True
         .ColAlignment(8) = UG_ALIGNRIGHT
                  
         .TextMatrix(0, 9) = "支出额(本位币)"
         .JoinCells 0, 9, 1, 9, True
         .ColAlignment(9) = UG_ALIGNRIGHT
                  
         .TextMatrix(0, 10) = "余额"
         .JoinCells 0, 10, 1, 10, True
         .ColAlignment(10) = UG_ALIGNRIGHT
         .ColWidth(10) = 1800
      
'         .TextMatrix(0, 10) = "余额(外币)"
'         .JoinCells 0, 10, 1, 10, True
'         .ColAlignment(10) = UG_ALIGNRIGHT
'         .ColWidth(10) = 1800
         '---------------------------------------
      End If
      
      .HeadFont.Name = "宋体"
      .HeadFont.Size = 9
      .HeadBackColor = &H8000000E
      .HeadFont.Bold = True
   End With

End Sub

'********************************************************************
'*函数说明: 填充显示Grid                                             *
'*参    数: strFill : 账户号                                          *
'*          rsFill : 记录集                                          *
'*          lngPfrom : 显示起始页号                                   *
'*          lngPto : 显示结束页号                                     *
'*返回值  : 期初余额                                                  *
'*********************************************************************
Private Sub FillDisplayGrid(strFill As String, rsFill As UfRecordset, lngPfrom As Long, lngPto As Long)
   Dim i As Long, j As Long, blnPrpty As Boolean
   Dim sqlClass As String, rsClass As New UfRecordset, strClass As String
   Dim curMb As Double
   Dim curMb_f As Double 'cuidong 对账单+外币 2001.12.04
   
   With rsFill
   .MoveFirst
   i = 0: j = 0
   If iDataSource = 1 Then
      blnPrpty = IIf(ZhDir = 1, True, False)
      With pzDzd
         ReDim .iBook(nMaxRows)
         ReDim .iPeriod(nMaxRows)
         ReDim .cSign(nMaxRows)
         ReDim .iNo_id(nMaxRows)
      End With
   End If
   
   While Not .EOF And i < lngPto * LinesPerPage
      If iDataSource = 0 Then
         If i = 0 Then
            curMb = dzdMb + ![Field5] - ![Field6]
            curMb_f = dzdMb_f + ![Field5_f] - ![Field6_f]
         Else
            curMb = curMb + ![Field5] - ![Field6]
            curMb_f = curMb_f + ![Field5_f] - ![Field6_f]
         End If
         sqlClass = "SELECT * FROM FD_Class WHERE [csign]='" & left(![Field3], 2) & "'"
         Set rsClass = dbsZJ.OpenRecordset(sqlClass, dbOpenSnapshot)
         If i >= (lngPfrom - 1) * LinesPerPage Then
'            UfGridado1.AddItem ![Field0] & Chr(9) & _
               ![Field1] & Chr(9) & _
               ![Field2] & Chr(9) & _
               rsClass![ctext] & "-" & Right(![Field3], Len(![Field3]) - 2) & Chr(9) & _
               ![Field4] & Chr(9) & _
               IIf(![Field5] = 0, "", FormatCur(![Field5])) & Chr(9) & _
               IIf(![Field6] = 0, "", FormatCur(![Field6]))             'cuidong 对账单+外币 2001.12.04
            UfGridADO1.AddItem ![Field0] & Chr(9) & _
               ![Field1] & Chr(9) & _
               ![Field2] & Chr(9) & _
               rsClass![ctext] & "-" & right(![Field3], Len(![Field3]) - 2) & Chr(9) & _
               ![transactions_id] & Chr(9) & _
               ![Field4] & Chr(9) & _
               IIf(![Field5] = 0, "", FormatCur(![Field5])) & Chr(9) & _
               IIf(![Field5_f] = 0, "", FormatCur(![Field5_f])) & Chr(9) & _
               IIf(![Field6] = 0, "", FormatCur(![Field6])) & Chr(9) & _
               IIf(![Field6_f] = 0, "", FormatCur(![Field6_f]))             'cuidong 对账单+外币 2001.12.04
'            UfGridado1.TextMatrix(j + nFixRows, 7) = FormatCur(curMb)      'cuidong 对账单+外币 2001.12.04
            UfGridADO1.TextMatrix(j + nFixRows, 8 + 2) = FormatCur(curMb)   'cuidong 对账单+外币 2001.12.04
''            UfGridADO1.TextMatrix(j + nFixRows, 8 + 3) = FormatCur(curMb_f) 'cuidong 对账单+外币 2001.12.04
            j = j + 1
         End If
      Else
         If i = 0 Then
            curMb = dzdMb + IIf(blnPrpty, ![Field5] - ![Field6], ![Field6] - ![Field5])
            curMb_f = dzdMb_f + IIf(blnPrpty, ![Field5_f] - ![Field6_f], ![Field6_f] - ![Field5_f])
         Else
            curMb = curMb + IIf(blnPrpty, ![Field5] - ![Field6], ![Field6] - ![Field5])
            curMb_f = curMb_f + IIf(blnPrpty, ![Field5_f] - ![Field6_f], ![Field6_f] - ![Field5_f])
         End If
         If i >= (lngPfrom - 1) * LinesPerPage And i < lngPto * LinesPerPage Then
'            UfGridado1.AddItem ![Field0] & Chr(9) & _
               ![Field1] & Chr(9) & _
               ![Field2] & Chr(9) & _
               ![Fieldx] & "-" & Right("000" & ![Field3], 3) & Chr(9) & _
               ![Field4] & Chr(9) & _
               IIf(![Field5] = 0, "", FormatCur(![Field5])) & Chr(9) & _
               IIf(![Field6] = 0, "", FormatCur(![Field6])) 'cuidong 对账单+外币 2001.12.04
            UfGridADO1.AddItem ![Field0] & Chr(9) & _
               ![Field1] & Chr(9) & _
               ![Field2] & Chr(9) & _
               ![Fieldx] & "-" & right("000" & ![Field3], 3) & Chr(9) & _
               ![Field4] & Chr(9) & _
               ![Field4] & Chr(9) & _
               IIf(![Field5] = 0, "", FormatCur(![Field5])) & Chr(9) & _
               IIf(![Field5_f] = 0, "", FormatCur(![Field5_f])) & Chr(9) & _
               IIf(![Field6] = 0, "", FormatCur(![Field6])) & Chr(9) & _
               IIf(![Field6_f] = 0, "", FormatCur(![Field6_f])) 'cuidong 对账单+外币 2001.12.04
            
'            UfGridado1.TextMatrix(j + nFixRows, 7) = ExcJd(IIf(blnPrpty, "借", "贷"), curMb)        'cuidong 对账单+外币 2001.12.04
'            UfGridado1.TextMatrix(j + nFixRows, 8) = IIf(curMb = 0, "", FormatCur(Abs(curMb)))      'cuidong 对账单+外币 2001.12.04
            UfGridADO1.TextMatrix(j + nFixRows, 8 + 2) = ExcJd(IIf(blnPrpty, "借", "贷"), curMb)     'cuidong 对账单+外币 2001.12.04
            UfGridADO1.TextMatrix(j + nFixRows, 9 + 2) = IIf(curMb = 0, "", FormatCur(Abs(curMb)))   'cuidong 对账单+外币 2001.12.04
''            UfGridADO1.TextMatrix(j + nFixRows, 9 + 2) = IIf(curMb_f = 0, "", FormatCur(Abs(curMb_f))) 'cuidong 对账单+外币 2001.12.04
            j = j + 1
         End If
         With pzDzd
            .cSign(i) = rsDisplay![Fieldx]
            .iBook(i) = rsDisplay![fColor]
            .iNo_id(i) = rsDisplay![Field3]
            .iPeriod(i) = rsDisplay![Fieldy]
         End With
      End If
      .MoveNext
      i = i + 1
   Wend
   End With
   UfGridADO1.Col = 0
   If UfGridADO1.Rows > 2 Then UfGridADO1.Row = 2
   
End Sub

Private Sub Form_Resize()
   Dim lngMid As Long
   Dim lngRight As Long
   Dim i As Integer
   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 - Picture2.Height - 400
'''''

⌨️ 快捷键说明

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