B
Bill_De
I Have a data base form that is tabbed to have several sub forms. I created
the first form "Contacts" and then created a form called "frmRegistration".
In
the registration form I have a combo box that I can select a building and
room number and then a query updates the table and removes the Check box
which is the availability or not.
Here is my problem I draged the frmRegistration over to the tab in the frm
contacts to make a sub form in tab 2. The frmContacts is in tab 1. If I fill
in all of the information in the registration form except a building and room
then click save the form saves the information and closes with no problem. If
however I enter the information and then click on the combo box named
Combo54, and select a building and room, then click save I get the following
error:
Run time Error 2450
Microsoft Access can't find the Form 'frmRegistration' referred to in a
Macro Expression or Visual Basic Code.
I then click on the debug button and the VB editor opens to my Combo54 code:
Private Sub Combo54_Exit (Cancel as Integer)
Dim db as DAO.Database
Dim qdf as QeuryDEF
Set qdf=db.Query Defs("Reserve Room")
{Yellow Highlight} qdf.Parameters(0). Value= Eval(qdf.Parameters(0).Name)
qdf.Execute dbFail on Error
Me.Combo54 Requery
When I put the cursor on the qdf.Parameters(0).Value I get the following
experssion: qdf.Parameters(0).Value=empty
When I put the cursor on the qdf.Parameters(0).Name I get the following
expression: qdf.Parameters(0).Name="[Forms]![frmRegistration]![Combo54]"
Any advise you can give me to correct this problem would be great. A note
the forms worked perfect (ran, updated, removed the selected room) until I
draged the registration form over to the second tab and made it a sub form of
the Contacts form. I am looking to remove the run time error so the form
works when draged over to the tab and made a subform
Thanks
Bill
the first form "Contacts" and then created a form called "frmRegistration".
In
the registration form I have a combo box that I can select a building and
room number and then a query updates the table and removes the Check box
which is the availability or not.
Here is my problem I draged the frmRegistration over to the tab in the frm
contacts to make a sub form in tab 2. The frmContacts is in tab 1. If I fill
in all of the information in the registration form except a building and room
then click save the form saves the information and closes with no problem. If
however I enter the information and then click on the combo box named
Combo54, and select a building and room, then click save I get the following
error:
Run time Error 2450
Microsoft Access can't find the Form 'frmRegistration' referred to in a
Macro Expression or Visual Basic Code.
I then click on the debug button and the VB editor opens to my Combo54 code:
Private Sub Combo54_Exit (Cancel as Integer)
Dim db as DAO.Database
Dim qdf as QeuryDEF
Set qdf=db.Query Defs("Reserve Room")
{Yellow Highlight} qdf.Parameters(0). Value= Eval(qdf.Parameters(0).Name)
qdf.Execute dbFail on Error
Me.Combo54 Requery
When I put the cursor on the qdf.Parameters(0).Value I get the following
experssion: qdf.Parameters(0).Value=empty
When I put the cursor on the qdf.Parameters(0).Name I get the following
expression: qdf.Parameters(0).Name="[Forms]![frmRegistration]![Combo54]"
Any advise you can give me to correct this problem would be great. A note
the forms worked perfect (ran, updated, removed the selected room) until I
draged the registration form over to the second tab and made it a sub form of
the Contacts form. I am looking to remove the run time error so the form
works when draged over to the tab and made a subform
Thanks
Bill