Hi all,
My main form has an unbound combo on it that is populated by a query. If no record is present i hit an add button which opens a form to add a new record. When i hit close on that form by CmdClose button, i want it to requery the combo on the main form so its not blank any longer. I have the following code but it just doens work. I have tried several methods but just cant get it to requery the combo. If I go out of record on main form and then back, then its there.
Code:Private Sub CmdClose_Click() If Me.NewRecord Then Me!Preferred = (DCount("PersonID", "Person2AddressTbl", "PersonID=" & Me.CboPerson & " AND Preferred = True") = 0) End If Forms!PersonFrm.Controls!CboAddressType.Requery Forms!PersonFrm.Refresh DoCmd.Close