suppressing warning?

CHAOSinACT

Registered User.
Local time
Today, 09:48
Joined
Mar 18, 2009
Messages
235
if i do this:
DoCmd.RunSQL "Delete * from tblOutlookFolders"

it prompts the user to confirm??? don't really want it to. anyone know a way round this? is just a temp table to hold values for a minute.
 
Use ...
Code:
CurrentDB.Execute "INSERT INTO ... "
 
yeah slipping this in worked too
Do Until TempRst.EOF
With TempRst
.Delete
.MoveNext
End With
Loop
TempRst.MoveFirst

but wondered if it could be suppressed within the .runSQL statement itself.
 
CHAOSinACT,

Please re-read lagbolt's post.

You can change:
Code:
DoCmd.RunSQL "Delete * from tblOutlookFolders"
...to:
Code:
CurrentDB.Execute "Delete * from tblOutlookFolders"
...in order to accomplish what you are after.
 
CHAOSinACT,

Please re-read lagbolt's post.

You can change:
Code:
DoCmd.RunSQL "Delete * from tblOutlookFolders"
...to:
Code:
CurrentDB.Execute "Delete * from tblOutlookFolders"
...in order to accomplish what you are after.

LMAO!!!! i was wondering how he thought an insert statement would help, didn't want to say anything. totally failed to notice the .Execute instead of the .RunSQL !!! *runs off to make some more coffee* lol. thanks for the pointer...
 
i thought so too. really need to stare at this screen a bit less lol...
 
The Execute is a better way but you can turn off warnings in Access with:
DoCmd.SetWarnings False

Note that this turns ALL the warnings off until you set it back to true or exit the application.
 

Users who are viewing this thread

Back
Top Bottom