Dear all,
I have a loop procedure to check whether there is an expired document should be remind to the user. There is no problem with this loop while the expired document is not more then 10 document. If the expired document is more then 10 the loop is stack and error.
here is my loop procedure
Sub KirimEmail()
Dim rst As New ADODB.Recordset
rst.Open "SELECT * FROM OverdueTasks", CurrentProject.Connection, adOpenForwardOnly, adLockReadOnly
If Not (rst.EOF And rst.BOF) Then
If IsSendEmail() Then
'Email semua Doc Terkait
rst.MoveFirst
Do Until rst.EOF
SendingEmail rst!DocNum, rst!email, rst!Action
rst.MoveNext
Loop
End If
End If
End Sub
I have a loop procedure to check whether there is an expired document should be remind to the user. There is no problem with this loop while the expired document is not more then 10 document. If the expired document is more then 10 the loop is stack and error.
here is my loop procedure
Sub KirimEmail()
Dim rst As New ADODB.Recordset
rst.Open "SELECT * FROM OverdueTasks", CurrentProject.Connection, adOpenForwardOnly, adLockReadOnly
If Not (rst.EOF And rst.BOF) Then
If IsSendEmail() Then
'Email semua Doc Terkait
rst.MoveFirst
Do Until rst.EOF
SendingEmail rst!DocNum, rst!email, rst!Action
rst.MoveNext
Loop
End If
End If
End Sub