I have a button that opens a for to the current record, unless there is no record at which point is opens the form in add mode:
If IsNull(Me.BorrowerInquiryID) Then
DoCmd.OpenForm "frmPasswords", acNormal, , , acFormAdd
DoCmd.OpenForm "frmPasswords", , , "[BorrowerInquiryID]= " & Me.BorrowerInquiryID & ""
This works fine; however, on frmPasswords I have a combo box that allows the user to chose another "borrower's inquiry." When I open the form directly from the navigation pane, the combo box works find; when I open the from with the button as programmed above, the combo box does not go to the selected record:
DoCmd.SearchForRecord , "", acFirst, "[VHDABorrowerInquiryID] = " & Str(Nz(Screen.ActiveControl, 0))
What can I do to my button's code so it does not lock the frmPassword to one record?