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

📄 maketrans.cls

📁 金算盘软件代码
💻 CLS
📖 第 1 页 / 共 5 页
字号:
                                                    intLoopLevel = 4 '        ------------本层的记录集已循环完,退到外层
                                                    Exit Do
                                                 End If
                                            End If
                                            
                                        End If
                                        intLoopLevel = 5
                                    End If
                                End If
                                '6------------------------------------------------------------------------
                                Do
                                    blnFirst = False
                                    intLoopLevel = 6
                                    If arrSelect(6) Then '本科目包括Class2核算
                                        If lngClassID2_MJ <> 0 Then '本科目为末级科目,且具有本种核算属性,并已具体设置了条件值
                                            intEditLevel = 6
                                            strClassID2 = lngClassID2_MJ
                                            dblValue = mclsBaseFun.EvalueFunc(NatureFunc, blnOK, strAccountId * Abs(arrSelect(0)), strCustomerID * Abs(arrSelect(1)), strDepartmentID * Abs(arrSelect(2)), strEmployeeID * Abs(arrSelect(3)), strJobID * Abs(arrSelect(4)), strClassID1 * Abs(arrSelect(5)), lngCurID, , strClassID2 * Abs(arrSelect(6)))
                                            If CurrencyFunc <> "" Then
                                                    lngResult = mclsBaseFun.SetCurrentCond(CurrencyFunc)
                                                    InitArr arrSelect2, lngResult
                                                    dblCurrValue = mclsBaseFun.EvalueFunc(CurrencyFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                   strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                            End If
                                            If QuantityFunc <> "" Then
                                                lngResult = mclsBaseFun.SetCurrentCond(QuantityFunc)
                                                InitArr arrSelect2, lngResult
                                                dblQuanValue = mclsBaseFun.EvalueFunc(QuantityFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                                  strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                            End If
                                            If blnOK = False Then Exit Function
                                            
                                            dblValue = Val(Format(dblValue, gclsBase.GetFormat(gclsBase.NaturalCurDec)))
                                            If dblValue <> 0 Then '将数据写入临时表
                                                If Not WriteTemp(arrAccount(), arrSelect(), lngTransVoucherID, lngTransVoucherDetailID, strAccountId, strCustomerID, strDepartmentID, strEmployeeID, strJobID, strClassID1, strClassID2, intDirection, dblValue, dblCurrValue, dblQuanValue) Then Exit Function
                                            End If
                                            Exit Do
                                        Else
                                            strSql = "SELECT Class2.* FROM Class2 Where blnIsDetail=1"
                                            Set recTemp_6 = gclsBase.BaseDB.OpenResultset(strSql, rdOpenStatic)
                                            If Not recTemp_6.EOF Then
                                                recTemp_6.MoveFirst
                                                strClassID2 = recTemp_6(0)
                                                                       
                                                intEditLevel = 6
                                                Do While Not recTemp_6.EOF
                                                    strClassID2 = recTemp_6(0)
                                                    dblValue = mclsBaseFun.EvalueFunc(NatureFunc, blnOK, strAccountId * Abs(arrSelect(0)), strCustomerID * Abs(arrSelect(1)), strDepartmentID * Abs(arrSelect(2)), strEmployeeID * Abs(arrSelect(3)), strJobID * Abs(arrSelect(4)), strClassID1 * Abs(arrSelect(5)), lngCurID, , strClassID2 * Abs(arrSelect(6)))
                                                    If CurrencyFunc <> "" Then
                                                        lngResult = mclsBaseFun.SetCurrentCond(CurrencyFunc)
                                                        InitArr arrSelect2, lngResult
                                                        dblCurrValue = mclsBaseFun.EvalueFunc(CurrencyFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                       strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                                    End If
                                                    If QuantityFunc <> "" Then
                                                        lngResult = mclsBaseFun.SetCurrentCond(QuantityFunc)
                                                        InitArr arrSelect2, lngResult
                                                        dblQuanValue = mclsBaseFun.EvalueFunc(QuantityFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                       strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                                    End If
                                                    If blnOK = False Then Exit Function
                                                    
                                                    dblValue = Val(Format(dblValue, gclsBase.GetFormat(gclsBase.NaturalCurDec)))
                                                    If dblValue <> 0 Then '将数据写入临时表
                                                        If Not WriteTemp(arrAccount(), arrSelect(), lngTransVoucherID, lngTransVoucherDetailID, strAccountId, strCustomerID, strDepartmentID, strEmployeeID, strJobID, strClassID1, strClassID2, intDirection, dblValue, dblCurrValue, dblQuanValue) Then Exit Function
                                                    End If
                                                    
                                                    recTemp_6.MoveNext
                                                Loop
                                                Exit Do
                                                
                                            Else
                                                 arrSelect(6) = False
                                                 Exit Do '退出循环
                                            End If
                                        End If
                                    End If
                                Loop While arrSelect(6)  '(6)
                                '------------------------------------------------------------------------
                                
                                If intEditLevel <= 5 Then '如果内层未执行(科目不包括上一曾的核算项目)
                                    If arrSelect(5) Then     '如果科目包括本级核算项目
                                        intEditLevel = 5
                                        If lngClassID1_MJ <> 0 Then
                                            strClassID1 = lngClassID1_MJ
                                            dblValue = mclsBaseFun.EvalueFunc(NatureFunc, blnOK, strAccountId * Abs(arrSelect(0)), strCustomerID * Abs(arrSelect(1)), strDepartmentID * Abs(arrSelect(2)), strEmployeeID * Abs(arrSelect(3)), strJobID * Abs(arrSelect(4)), strClassID1 * Abs(arrSelect(5)), lngCurID, , strClassID2 * Abs(arrSelect(6)))
                                            If CurrencyFunc <> "" Then
                                                    lngResult = mclsBaseFun.SetCurrentCond(CurrencyFunc)
                                                    InitArr arrSelect2, lngResult
                                                    dblCurrValue = mclsBaseFun.EvalueFunc(CurrencyFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                   strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                            End If
                                            If QuantityFunc <> "" Then
                                                lngResult = mclsBaseFun.SetCurrentCond(QuantityFunc)
                                                InitArr arrSelect2, lngResult
                                                dblQuanValue = mclsBaseFun.EvalueFunc(QuantityFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                               strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                            End If
                                            If blnOK = False Then Exit Function
                                            
                                            dblValue = Val(Format(dblValue, gclsBase.GetFormat(gclsBase.NaturalCurDec)))
                                            If dblValue <> 0 Then '将数据写入临时表
                                                  If Not WriteTemp(arrAccount(), arrSelect(), lngTransVoucherID, lngTransVoucherDetailID, strAccountId, strCustomerID, strDepartmentID, strEmployeeID, strJobID, strClassID1, strClassID2, intDirection, dblValue, dblCurrValue, dblQuanValue) Then Exit Function
                                            End If
                                        Else
                                            recTemp_5.MoveFirst
                                            Do While Not recTemp_5.EOF
                                                strClassID1 = recTemp_5(0)
                                                dblValue = mclsBaseFun.EvalueFunc(NatureFunc, blnOK, strAccountId * Abs(arrSelect(0)), strCustomerID * Abs(arrSelect(1)), strDepartmentID * Abs(arrSelect(2)), strEmployeeID * Abs(arrSelect(3)), strJobID * Abs(arrSelect(4)), strClassID1 * Abs(arrSelect(5)), lngCurID, , strClassID2 * Abs(arrSelect(6)))
                                                If CurrencyFunc <> "" Then
                                                    lngResult = mclsBaseFun.SetCurrentCond(CurrencyFunc)
                                                    InitArr arrSelect2, lngResult
                                                    dblCurrValue = mclsBaseFun.EvalueFunc(CurrencyFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                   strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                                End If
                                                If QuantityFunc <> "" Then
                                                        lngResult = mclsBaseFun.SetCurrentCond(QuantityFunc)
                                                        InitArr arrSelect2, lngResult
                                                        dblQuanValue = mclsBaseFun.EvalueFunc(QuantityFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                       strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                                End If
                                                If blnOK = False Then Exit Function
                                                
                                                dblValue = Val(Format(dblValue, gclsBase.GetFormat(gclsBase.NaturalCurDec)))
                                                If dblValue <> 0 Then '将数据写入临时表
                                                      If Not WriteTemp(arrAccount(), arrSelect(), lngTransVoucherID, lngTransVoucherDetailID, strAccountId, strCustomerID, strDepartmentID, strEmployeeID, strJobID, strClassID1, strClassID2, intDirection, dblValue, dblCurrValue, dblQuanValue) Then Exit Function
                                                End If
                                                
                                                recTemp_5.MoveNext
                                            Loop
                                        End If
                                        intLoopLevel = 5
                                        Exit Do
                                    Else
                                        intLoopLevel = 5
                                        Exit Do
                                    End If
                                End If
                            Loop While arrSelect(5)  '(5)
                            '------------------------------------------------------------------------
                            
                            If intEditLevel <= 4 Then '如果内层未执行(科目不包括上一曾的核算项目)
                                If arrSelect(4) Then     '如果科目包括本级核算项目
                                    intEditLevel = 4
                                    If lngJobID_MJ <> 0 Then
                                        strJobID = lngJobID_MJ
                                        dblValue = mclsBaseFun.EvalueFunc(NatureFunc, blnOK, strAccountId * Abs(arrSelect(0)), strCustomerID * Abs(arrSelect(1)), strDepartmentID * Abs(arrSelect(2)), strEmployeeID * Abs(arrSelect(3)), strJobID * Abs(arrSelect(4)), strClassID1 * Abs(arrSelect(5)), lngCurID, , strClassID2 * Abs(arrSelect(6)))
                                        If CurrencyFunc <> "" Then
                                                lngResult = mclsBaseFun.SetCurrentCond(CurrencyFunc)
                                                InitArr arrSelect2, lngResult
                                                dblCurrValue = mclsBaseFun.EvalueFunc(CurrencyFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                               strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                        End If
                                        If QuantityFunc <> "" Then
                                                lngResult = mclsBaseFun.SetCurrentCond(QuantityFunc)
                                                InitArr arrSelect2, lngResult
                                                dblQuanValue = mclsBaseFun.EvalueFunc(QuantityFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                               strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                        End If
                                        If blnOK = False Then Exit Function
                                        
                                        dblValue = Val(Format(dblValue, gclsBase.GetFormat(gclsBase.NaturalCurDec)))
                                        If dblValue <> 0 Then '将数据写入临时表
                                            If Not WriteTemp(arrAccount(), arrSelect(), lngTransVoucherID, lngTransVoucherDetailID, strAccountId, strCustomerID, strDepartmentID, strEmployeeID, strJobID, strClassID1, strClassID2, intDirection, dblValue, dblCurrValue, dblQuanValue) Then Exit Function
                                        End If
                                    Else
                                        recTemp_4.MoveFirst
                                        Do While Not recTemp_4.EOF
                                            strJobID = recTemp_4(0)
                                            dblValue = mclsBaseFun.EvalueFunc(NatureFunc, blnOK, strAccountId * Abs(arrSelect(0)), strCustomerID * Abs(arrSelect(1)), strDepartmentID * Abs(arrSelect(2)), strEmployeeID * Abs(arrSelect(3)), strJobID * Abs(arrSelect(4)), strClassID1 * Abs(arrSelect(5)), lngCurID, , strClassID2 * Abs(arrSelect(6)))
                                            If CurrencyFunc <> "" Then
                                                    lngResult = mclsBaseFun.SetCurrentCond(CurrencyFunc)
                                                    InitArr arrSelect2, lngResult
                                                    dblCurrValue = mclsBaseFun.EvalueFunc(CurrencyFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                   strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                            End If
                                            If QuantityFunc <> "" Then
                                                    lngResult = mclsBaseFun.SetCurrentCond(QuantityFunc)
                                                    InitArr arrSelect2, lngResult
                                                    dblQuanValue = mclsBaseFun.EvalueFunc(QuantityFunc, blnOK, strAccountId * Abs(arrSelect2(0)), strCustomerID * Abs(arrSelect2(1)), strDepartmentID * Abs(arrSelect2(2)), _
                                                                   strEmployeeID * Abs(arrSelect2(3)), strJobID * Abs(arrSelect2(4)), strClassID1 * Abs(arrSelect2(5)), lngCurID, , strClassID2 * Abs(arrSelect2(6)))
                                            End If

⌨️ 快捷键说明

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