J
John
I am trying to run in code, a series of delete queries,
append queries and printing reports. After it gets to the
last part of the code, it give me a memory error message
and then kicks me out of Access.
If I run the queries manually one after the other, I do
not get a memory error message.
Am I doing something wrong in my code to cause this
error?
THANKS IN ADVANCE!!!
Here is my code:
Dim stdocName1 As String
Dim stdocName2 As String
Dim stdocname3 As String
Dim stdocname4 As String
Dim stdocname5 As String
Dim stDocName6 As String
Dim stDocName7 As String
Need to clear out tbltoolwatchbad, tbltoolwatchvalidate
and tbltoolwatchexport tables
stdocName1 = "DeltblToolWatchBad"
DoCmd.OpenQuery stdocName1, acNormal, acEdit
stdocName2 = "DeltblToolWatchValidate"
DoCmd.OpenQuery stdocName2, acNormal, acEdit
stdocname3 = "DeltblToolWatchExport"
DoCmd.OpenQuery stdocname3, acNormal, acEdit
'Append new tool records to tblToolWatchexport Table
stdocname4 = "AppNewToolRecords"
DoCmd.OpenQuery stdocname4, acNormal, acEdit
'Append new transfer records to tblToolWatchValidate table
'These records need to be validated
stdocname5 = "AppNewTransferRecords"
DoCmd.OpenQuery stdocname5, acNormal, acEdit
'Print outs of "Special Records" and "Jobs Not Open"
stDocName6 = "Jobs Not Open Report"
DoCmd.OpenReport stDocName6, acNormal
stDocName7 = "Jobs Not Open Report"
DoCmd.OpenReport stDocName7, acNormal
append queries and printing reports. After it gets to the
last part of the code, it give me a memory error message
and then kicks me out of Access.
If I run the queries manually one after the other, I do
not get a memory error message.
Am I doing something wrong in my code to cause this
error?
THANKS IN ADVANCE!!!
Here is my code:
Dim stdocName1 As String
Dim stdocName2 As String
Dim stdocname3 As String
Dim stdocname4 As String
Dim stdocname5 As String
Dim stDocName6 As String
Dim stDocName7 As String
Need to clear out tbltoolwatchbad, tbltoolwatchvalidate
and tbltoolwatchexport tables
stdocName1 = "DeltblToolWatchBad"
DoCmd.OpenQuery stdocName1, acNormal, acEdit
stdocName2 = "DeltblToolWatchValidate"
DoCmd.OpenQuery stdocName2, acNormal, acEdit
stdocname3 = "DeltblToolWatchExport"
DoCmd.OpenQuery stdocname3, acNormal, acEdit
'Append new tool records to tblToolWatchexport Table
stdocname4 = "AppNewToolRecords"
DoCmd.OpenQuery stdocname4, acNormal, acEdit
'Append new transfer records to tblToolWatchValidate table
'These records need to be validated
stdocname5 = "AppNewTransferRecords"
DoCmd.OpenQuery stdocname5, acNormal, acEdit
'Print outs of "Special Records" and "Jobs Not Open"
stDocName6 = "Jobs Not Open Report"
DoCmd.OpenReport stDocName6, acNormal
stDocName7 = "Jobs Not Open Report"
DoCmd.OpenReport stDocName7, acNormal