Hi,
I've been attempting to piece this together based on other posts I've seen and still having a problem. Probably obvious but here's what I have. I have a form with an option group at the top named FrameMissing. Based on the option selected, I would like the subform windown below to show a list of records in a premade query. The subform window is called Qmissing. I've never made a form like this before so I am unsure of how to link the subform to the option group selection. The code I came up with based on examples I found is:
Private Sub FrameMissing_AfterUpdate()
Dim qryName As String
Select Case FrameMissing
Case 1
qryName = "BudgetedCC"
Case 2
qryName = "BudgetedSal"
Case 3
qryName = "BudgetedStart"
Case 4
qryName = "ActualCC"
Case 5
qryName = "ActualSal"
Case 6
qryName = "ActualStart"
Case 7
qryName = "ForeStart"
Case 8
qryName = "ForeSal"
End Select
Me.QMissing.Form.RecordSource = qryName
End Sub
Anyone have ideas of what I missed?
Thanks!
I've been attempting to piece this together based on other posts I've seen and still having a problem. Probably obvious but here's what I have. I have a form with an option group at the top named FrameMissing. Based on the option selected, I would like the subform windown below to show a list of records in a premade query. The subform window is called Qmissing. I've never made a form like this before so I am unsure of how to link the subform to the option group selection. The code I came up with based on examples I found is:
Private Sub FrameMissing_AfterUpdate()
Dim qryName As String
Select Case FrameMissing
Case 1
qryName = "BudgetedCC"
Case 2
qryName = "BudgetedSal"
Case 3
qryName = "BudgetedStart"
Case 4
qryName = "ActualCC"
Case 5
qryName = "ActualSal"
Case 6
qryName = "ActualStart"
Case 7
qryName = "ForeStart"
Case 8
qryName = "ForeSal"
End Select
Me.QMissing.Form.RecordSource = qryName
End Sub
Anyone have ideas of what I missed?
Thanks!