no it's not
Main Topics
Browse All TopicsI am trying to set any notifications off when using a macro (such as notification to create a table, etc)... but in Access 2007 when I entered SetWarnings in action field it gave me an error message "The Text you entered isn't an item in the list"....
Please advice
Thanks
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
"organization might have disabled it."
I don't think Access is that granular wherein that specific item in that list could be removed. I don't have A2007 loaded, but this all does sound a tad familiar.
You can get around this in vba code .. with a much safer approach anyway than using SetWarnings ... which is dangerous in general and can mask errors that you don't want masked.
mx
Let me suggest a safer way ... that gets away from the SetWarnings False - which can have many undesirable ramifications.
The problem with SetWarnings False is ... if one (or more) of the queries fail for *whatever* unexpected reason ... you will never know this because SetWarnings False masks out *all* errors, which can lead to you *thinking* that everything ran ok, when in fact it did not.
The approach below has two advantages:
1) You do not get the warning prompts - just like if you use SetWarnings False ... AND ...
2) If an Error DOES occur, it will be trapped and you can act accordingly.
Private Sub btnRunQry_Click()
On Error GoTo btnRunQry_Click_Error
CurrentDb.Execute "SomeActionQuery1", dbFailOnError
CurrentDb.Execute "SomeActionQuery2", dbFailOnError
MsgBox "Operation completed successfully!"
btnRunQry_Click_Exit:
Err.Clear
Exit Sub
btnRunQry_Click_Error:
MsgBox "An error occurred:" & vbCrLf & Err.Number & vbCrLf & Err.Description
GoTo btnRunQry_Click_Exit
End Sub
******
Another problem with SetWarnings False is ... if you *forget* to execute SetWarnings True ... OR ... some other error does occur and SetWarnings True does not get execute ... you have a big problem ... because, False stays in effect unit you close and reopen Access.
So, for example if you are working in design view of say a form (or table, etc) ... and you make some changes ... and hit Save ... you are NOT prompted for 'Do you want to save these changes ...". I will just silently save the changes ... which may NOT be what you wanted to do!!
mx
Business Accounts
Answer for Membership
by: DatabaseMXPosted on 2009-11-02 at 09:02:12ID: 25721154
"when I entered SetWarnings"
Is that not in the drop down list ?