OK, , So this is not quite the way I would do things. So the button on the main form would have code like the following behind it.
DoCmd.OpenForm "popupformname",,,"LoanID = " & Me.LoanID
That would open the Popup form for Notes for the Loan currently displayed in the Main form.
On the Popup form, I would not use Datasheet view. I would use a Continuous form view so you can use have greater control over your data entry. This way you could have a larger text box for the Notes field for example.
The next thing I would do is put a combobox (you can use a listbox if you need to see more info about each loan) in the form header. This control could be filtered for the loans as indicated. I would, then, use the following snippets of code:
In the On Open Event I would use
Me.controlname = Me.LoanID
This would set the control in the header to be the LoanID in the calling form.
Then, in the After Update event of that control I would have code like:
Me.Filter = "LoanID = " & Me.controlname
DoCmd.RunCommand acCmdApplyFilterSort
So, after you select a new Loan in that list control, you will now see Notes for the loan selected.
I would also set the Default Value for the LoanID control to
Forms!popupformname!controlname
So new records would pickup the LoanID from the list control in the header.
That should allow you to add new Notes for different loans from the popup form.
OK, For the Option group issue since you want a range of days, Then I would use code like the following in the After Update Event of the Option Group.
Dim strSQL As String
strSQL = "SELECT field list FROM table "
SELECT Case Me.optiongroupname
Case 1
strSQL = strSQL & "WHERE CloseDate < Date()+10;"
Case 2
strSQL = strSQL & "WHERE CloseDate > Date()+10;"
Case 3
strSQL = strSQL & "WHERE CloseDate BETWEEN Date()+45 AND Date()+60;"
Case 4
strSQL = strSQL & "WHERE CloseDate BETWEEN Date()+90 AND Date()+120;"
Case Else
strSQL = strSQL & ";"
End Select
Me.controlname.RowSource = strSQL
Me.controlname.Requery