BigOrangeMonkey
Programmer
Hi,
I am using the following code to set the ReturnsRecords value of my PassThrough QueryDefs to false, when I step through the code using the debugger it works fine, but when I let the program run without stepping through it doesnt work! Any Ideas because this is really driving me up the wall!
Code :
I am using the following code to set the ReturnsRecords value of my PassThrough QueryDefs to false, when I step through the code using the debugger it works fine, but when I let the program run without stepping through it doesnt work! Any Ideas because this is really driving me up the wall!
Code :
Code:
Private Sub SetReturnsRecords()
Dim Linkdb As Database
Dim PTQuery1 As QueryDef
Dim PTQuery2 As QueryDef
Dim PTQuery3 As QueryDef
Dim PTQuery4 As QueryDef
Set Linkdb = OpenDatabase(Application.CurrentProject.FullName)
Set PTQuery1 = Linkdb.QueryDefs("Truncate QLS-LAD Tables")
Set PTQuery2 = Linkdb.QueryDefs("Update U_Version")
Set PTQuery3 = Linkdb.QueryDefs("uversion_ladlearningaim_1")
Set PTQuery4 = Linkdb.QueryDefs("uversion_ladlearningaim_2")
PTQuery1.ReturnsRecords = False
PTQuery2.ReturnsRecords = False
PTQuery3.ReturnsRecords = False
PTQuery4.ReturnsRecords = False
End Sub