I don't know why you're getting the error, but if the query will run if you
don't use the SetWarnings statement, you may be able to use a different
syntax to run the query.
CurrentDb.Execute "QueryName", dbFailOnError
This will run the query without prompting you. It will return an error if
the query fails to complete successfully.

Signature
Wayne Morgan
MS Access MVP
>I have an Access form that when I click the update button it starts a
>series of queries one of which is an update query that has an iif statment
[quoted text clipped - 9 lines]
>
> Job
Job - 09 Aug 2005 04:44 GMT
> I don't know why you're getting the error, but if the query will run if you
> don't use the SetWarnings statement, you may be able to use a different
[quoted text clipped - 4 lines]
> This will run the query without prompting you. It will return an error if
> the query fails to complete successfully.
Wayne,
That did the trick!
Cheers,
Job