G
graeme34 via AccessMonster.com
Hi could anybody help a newbie out!
I have a form that has a child form whose control source is a temp table
based on a make table query. Originally I tried to have the control source a
cross tab query but it turned out these are not editable.
I have the sub form accepting data now, my only problem is when exiting the
form I want to Docmd.OpenQuery on the make table query thus updating its
contents.
I have tried placing the code in all of the forms events, but it keeps coming
back with the runtime error "3211" The databaseengine could not lock the
table "tblTempGoodsRecieved" as it is in use by another person. I'm assuming
this is because the Form "frmReceivePurchaseOrder" is still open.
The code I'm trying to implement is:
DoCmd.OpenQuery "qryMakeReceiveTable"
DoCmd.Close acQuery, "qryMakeReceiveTable"
I have tried placing this in the Onclose, on deactivate events, on lost focus
but none seem to prevent the run time error, any suggestions??
Also is there away to prevent the warning message coming up about old temp
table being deleted before running the make table query??
Thanks.
I have a form that has a child form whose control source is a temp table
based on a make table query. Originally I tried to have the control source a
cross tab query but it turned out these are not editable.
I have the sub form accepting data now, my only problem is when exiting the
form I want to Docmd.OpenQuery on the make table query thus updating its
contents.
I have tried placing the code in all of the forms events, but it keeps coming
back with the runtime error "3211" The databaseengine could not lock the
table "tblTempGoodsRecieved" as it is in use by another person. I'm assuming
this is because the Form "frmReceivePurchaseOrder" is still open.
The code I'm trying to implement is:
DoCmd.OpenQuery "qryMakeReceiveTable"
DoCmd.Close acQuery, "qryMakeReceiveTable"
I have tried placing this in the Onclose, on deactivate events, on lost focus
but none seem to prevent the run time error, any suggestions??
Also is there away to prevent the warning message coming up about old temp
table being deleted before running the make table query??
Thanks.