📄 maketrans.cls
字号:
End If
If Not recTemp_1.EOF Then
strCustomerID = recTemp_1(0)
Else
intLoopLevel = 0 ' ------------本层的记录集已循环完,退到外层
Exit Do
End If
End If
End If
intLoopLevel = 1
End If
End If
'2------------------------------------------------------------------------
Do
If arrSelect(2) Then '如果科目包括本层的核算项目,则打开所有的核算明细记录
If lngDepartmentID_MJ <> 0 Then '本科目为末级科目,且具有本种核算属性,并已具体设置了条件值
If intLoopLevel <= 1 Then
strDepartmentID = lngDepartmentID_MJ
intLoopLevel = 2
Else
Exit Do '------------本层由内层退出时调用(直接退出本层循环)
End If
Else
If blnFirst Then ' ------------本层第一次调用(打开记录集)
strSql = "SELECT Department.* FROM Department Where blnIsDetail=1"
Set recTemp_2 = gclsBase.BaseDB.OpenResultset(strSql, rdOpenStatic)
If recTemp_2.BOF And recTemp_2.EOF Then
arrSelect(2) = False '记录集为空,相当于不包括本层核算
Else
recTemp_2.MoveFirst
strDepartmentID = recTemp_2(0)
End If
Else
If intLoopLevel <= 1 Then ' ------------本层由外层调用(需将记录集移到开始处)
recTemp_2.MoveFirst
strDepartmentID = recTemp_2(0)
Else
If Not recTemp_2.EOF Then
recTemp_2.MoveNext
End If
If Not recTemp_2.EOF Then ' ------------本层由内层退出时调用(移动已打开的记录集的指针到下条记录)
strDepartmentID = recTemp_2(0)
Else
intLoopLevel = 1 ' ------------本层的记录集已循环完,退到外层(让外层继续循环)
Exit Do
End If
End If
End If
intLoopLevel = 2
End If
End If
'3------------------------------------------------------------------------
Do
If arrSelect(3) Then '如果科目包括本层的核算项目,则打开所有的核算明细记录
If lngEmployeeID_MJ <> 0 Then '本科目为末级科目,且具有本种核算属性,并已具体设置了条件值
If intLoopLevel <= 2 Then
strEmployeeID = lngEmployeeID_MJ
intLoopLevel = 3
Else
Exit Do '------------本层由内层退出时调用(直接退出本层循环)
End If
Else
If blnFirst Then ' ------------本层第一次调用(打开记录集)
strSql = "SELECT Employee.* FROM Employee"
Set recTemp_3 = gclsBase.BaseDB.OpenResultset(strSql, rdOpenStatic)
If recTemp_3.BOF And recTemp_3.EOF Then
arrSelect(3) = False '记录集为空,相当于不包括本层核算
Else
recTemp_3.MoveFirst
strEmployeeID = recTemp_3(0)
End If
Else
If intLoopLevel <= 2 Then ' ------------本层由外层调用(需将记录集移到开始处)
recTemp_3.MoveFirst
strEmployeeID = recTemp_3(0)
Else
If Not recTemp_3.EOF Then
recTemp_3.MoveNext
End If
If Not recTemp_3.EOF Then ' ------------本层由内层退出时调用(移动已打开的记录集的指针到下条记录)
strEmployeeID = recTemp_3(0)
Else
intLoopLevel = 2 ' ------------本层的记录集已循环完,退到外层
Exit Do
End If
End If
End If
intLoopLevel = 3
End If
End If
'4------------------------------------------------------------------------
Do
If arrSelect(4) Then '如果科目包括本层的核算项目,则打开所有的核算明细记录
If lngJobID_MJ <> 0 Then '本科目为末级科目,且具有本种核算属性,并已具体设置了条件值
If intLoopLevel <= 3 Then
strJobID = lngJobID_MJ
intLoopLevel = 4
Else
Exit Do '------------本层由内层退出时调用(直接退出本层循环)
End If
Else
If blnFirst Then ' ------------本层第一次调用(打开记录集)
strSql = "SELECT JOb.* FROM JOb"
Set recTemp_4 = gclsBase.BaseDB.OpenResultset(strSql, rdOpenStatic)
If recTemp_4.BOF And recTemp_4.EOF Then
arrSelect(4) = False '记录集为空,相当于不包括本层核算
Else
recTemp_4.MoveFirst
strJobID = recTemp_4(0)
End If
Else
If intLoopLevel <= 3 Then ' ------------本层由外层调用(需将记录集移到开始处)
recTemp_4.MoveFirst
strJobID = recTemp_4(0)
Else
If Not recTemp_4.EOF Then
recTemp_4.MoveNext
End If
If Not recTemp_4.EOF Then ' ------------本层由内层退出时调用(移动已打开的记录集的指针到下条记录)
strJobID = recTemp_4(0)
Else
intLoopLevel = 3 ' ------------本层的记录集已循环完,退到外层
Exit Do
End If
End If
End If
intLoopLevel = 4
End If
End If
'5------------------------------------------------------------------------
Do
If arrSelect(5) Then '如果科目包括本层的核算项目,则打开所有的核算明细记录
If lngClassID1_MJ <> 0 Then '本科目为末级科目,且具有本种核算属性,并已具体设置了条件值
If intLoopLevel <= 4 Then
strClassID1 = lngClassID1_MJ
intLoopLevel = 5
Else
Exit Do '------------本层由内层退出时调用(直接退出本层循环)
End If
Else
If blnFirst Then ' ------------本层第一次调用(打开记录集)
strSql = "SELECT Class1.* FROM Class1 Where blnIsDetail=1"
Set recTemp_5 = gclsBase.BaseDB.OpenResultset(strSql, rdOpenStatic)
If recTemp_5.BOF And recTemp_5.EOF Then
arrSelect(5) = False '记录集为空,相当于不包括本层核算
Else
recTemp_5.MoveFirst
strClassID1 = recTemp_5(0)
End If
Else
If intLoopLevel <= 4 Then ' ------------本层由外层调用(需将记录集移到开始处)
recTemp_5.MoveFirst
strClassID1 = recTemp_5(0)
mintCount = mintCount + 1
If mintCount > 1000 Then
ShowMsg frmMain.hwnd, "公式计算出现意外错误,转帐失败!", vbInformation + vbOKOnly, App.title
mintCount = 0
CalFunction = False
Exit Function
End If
Else
If Not recTemp_5.EOF Then
If Not recTemp_5.EOF Then
recTemp_5.MoveNext
End If
If Not recTemp_5.EOF Then ' ------------本层由内层退出时调用(移动已打开的记录集的指针到下条记录)
strClassID1 = recTemp_5(0)
Else
intLoopLevel = 4 ' ------------本层的记录集已循环完,退到外层
Exit Do
End If
Else
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -