Hello, I have a Time Entry Form that has a subform which is unlinked. There are a series of buttons on the main form that build the subform recordsource based on the user selection. This worked well and something has happened.
What happens now is when the user makes his selection, the 2467 error about the subform not existing displays.
However, if I go to design view and then back to form view the subform works and updates as it should. If I close the form, open another form and come back to the time form the problem repeats itself.
If I log off and then back on as another person and run through the routine it errors again. If I go to design view and then back to form view it works fine.
This is the code. Red is the error:
Private Sub FrameItemType_AfterUpdate()
stSqlTR 'Function to Create subform Recordsource
Forms!frmTime.frmTimeSub.Form.RecordSource = stSqlTR
Forms!frmTime.frmTimeSub.Form.Requery
Me.frmTimeSub.Visible = True
End Sub
I've tried removing the subform and putting it back - same problem. Any suggestions on this?
What happens now is when the user makes his selection, the 2467 error about the subform not existing displays.
However, if I go to design view and then back to form view the subform works and updates as it should. If I close the form, open another form and come back to the time form the problem repeats itself.
If I log off and then back on as another person and run through the routine it errors again. If I go to design view and then back to form view it works fine.
This is the code. Red is the error:
Private Sub FrameItemType_AfterUpdate()
stSqlTR 'Function to Create subform Recordsource
Forms!frmTime.frmTimeSub.Form.RecordSource = stSqlTR
Forms!frmTime.frmTimeSub.Form.Requery
Me.frmTimeSub.Visible = True
End Sub
I've tried removing the subform and putting it back - same problem. Any suggestions on this?