Use this instead If CurrentProject.AllForms("frmWorkOrder").IsLoaded = True Then Forms!frmWorkOrder.cboAssignID.Requery End if
"SHIPP" wrote:
[Quoted Text] > I have a form where I am using the double click event of a combo box to open > up another form so that I can add additional records for the combo box. On > the close event of this second form I have the following code: > > If Forms!frmWorkOrder.IsLoaded = True Then > Forms!frmWorkOrder.cboAssignID.Requery > End If > > The desired result is to requery the combo box on my primary form so that I > can now see the added record. The error I get is Erro 2465 > Application-defined or object-defined error. > > In addition if I simply open up the secondary form to add a record without > the primary form being open I get Error 2450 can't find frmWorkOrder. > > I have tried to put the code in the close event as well as the unload event. > The errors occur either way. Any help would be appreciated. > -- > M. Shipp
|