T
Todd
I'm baffled. I have frmMain and frmSub. On frmMain, I have chkMain1,
chkMain2, chkMain3. On frmSub I have chkSub1, chkSub2
When I click a button on the main form, it runs code like this...
If Me!chkMain1 = True Then...
If Me!chkMain2 = True Then...
If Me!chkMain3 = True Then...
If Me!frmSub!chkSub1 = True Then...
If Me!frmSub!chkSub2 = True Then...
Actually, I loop the code above but I thought it would be easier to
understand if I listed it out. Anyways, all of the chkMain tests work
perfectly every time. The checkboxes on the subform, however, are acting
very erratic. Sometimes chkSub1 will test true even if it is false as will
chkSub2. I can't figure out why. I tried adding Forms!frmMain.Refresh but
that didn't help.
---
I'm not sure that you need this info, but I'll provide it just in case. The
above mentioned code is actually done via a loop. My checkbox field names
are stored in a table (field name is txtDbaseField). The ones in the main
subform are stored as chkMain1 and the ones in the subform are stored as
frmSub!chkSub1 and brought up with this code:
Dim rstFiles As Recordset
Set rstFiles = CurrentDb.OpenRecordset("TLA-Files")
Do While Not rstFiles.EOF
If Me(rstFiles!txtDbaseField) = True Then
...Do some stuff...
End If
rstFiles.MoveNext
Loop
rstFiles.Close
chkMain2, chkMain3. On frmSub I have chkSub1, chkSub2
When I click a button on the main form, it runs code like this...
If Me!chkMain1 = True Then...
If Me!chkMain2 = True Then...
If Me!chkMain3 = True Then...
If Me!frmSub!chkSub1 = True Then...
If Me!frmSub!chkSub2 = True Then...
Actually, I loop the code above but I thought it would be easier to
understand if I listed it out. Anyways, all of the chkMain tests work
perfectly every time. The checkboxes on the subform, however, are acting
very erratic. Sometimes chkSub1 will test true even if it is false as will
chkSub2. I can't figure out why. I tried adding Forms!frmMain.Refresh but
that didn't help.
---
I'm not sure that you need this info, but I'll provide it just in case. The
above mentioned code is actually done via a loop. My checkbox field names
are stored in a table (field name is txtDbaseField). The ones in the main
subform are stored as chkMain1 and the ones in the subform are stored as
frmSub!chkSub1 and brought up with this code:
Dim rstFiles As Recordset
Set rstFiles = CurrentDb.OpenRecordset("TLA-Files")
Do While Not rstFiles.EOF
If Me(rstFiles!txtDbaseField) = True Then
...Do some stuff...
End If
rstFiles.MoveNext
Loop
rstFiles.Close