I have this code:
What I'm trying to do is to set the boolean variables from EmptyFields_Per iod1 to EmptyFields_Per iod5 to TRUE at the beginning of the loop and then if certain conditions are met set it to FALSE, but posted code is clearly not a good syntax.
Tnx.
Code:
For COUNT = 1 To 5
EmptyFields_Period [COUNT] = True
For Each ctl In Form_frmMain.Controls
If ctl.ControlType = acTextBox Then
If ctl.Tag = "Period" & COUNT Then
If ctl <> "" Then
EmptyFields_Period [COUNT] = False
End If
End If
End If
Next ctl
Next COUNT
Tnx.
Comment