ComboBox works only when target form is initialized

Ccar

New member
Local time
Yesterday, 18:56
Joined
Jul 1, 2013
Messages
2
Hi all,

Looking for a bit of direction with what seems a simple issue. I have two forms. In form 1, there is a combo box that I have set on click to open form 2 in this manner:

Code:
Private Sub boxEditEntry_Click()
    DoCmd.OpenForm "frmSRTEdit", , , "[ControlNumber]=" & Me.boxEditEntry
End Sub
The thing is, this has only worked when Form 2 is already open. I can't figure out why. If Form 2 is not open or has not been opened, the on click will still open Form 2, but not to the value in the combo box, or any value for that matter, it's blank. I really need it open if has not yet been opened or if it has been closed before. Also, I'm fairly new to access and I have no clue what I'm doing in vb.

Any ideas?
 
Change to After Update Event.

Dale
 
Works perfect, I knew it was something simple. Thanks
 

Users who are viewing this thread

Back
Top Bottom