Listbox Troubles

attachment.php


Thanks Bob... Here is the funny thing... I changed the join on the qry and now the form updates... however I still get the Runtime 2450 error saying it can't find the form. It updates the listbox okay but the error still appears...

Any thoughts?
 

Attachments

The error happens if you don't have the frmSysEnt form open at the time you add a new entitlement. To solve that just change your frmEntitlement's After Update code to this:
Code:
Private Sub Form_AfterUpdate()
    [COLOR=red]If CurrentProject.AllForms("frmSysEnt").IsLoaded Then
[/COLOR]        Forms!frmSysEnt.lboAllEnt.Requery
        Forms!frmSysEnt.lboCurrentEnt.Requery
    [COLOR=red]End If[/COLOR]
End Sub
 
The error happens if you don't have the frmSysEnt form open at the time you add a new entitlement. To solve that just change your frmEntitlement's After Update code to this:
Code:
Private Sub Form_AfterUpdate()
    [COLOR=red]If CurrentProject.AllForms("frmSysEnt").IsLoaded Then[/COLOR]
        Forms!frmSysEnt.lboAllEnt.Requery
        Forms!frmSysEnt.lboCurrentEnt.Requery
    [COLOR=red]End If[/COLOR]
End Sub


Great, thanks Bob.
 

Users who are viewing this thread

Back
Top Bottom