Access 2007 Macro Conditions


David Weiss

I am trying to set up a macro in Access 2007 to look at a table "UPDATE"; if
field "Date" equals today and field "Update Status" equals "Yes" the macro
should run the action RunSavedImportExport. It seems that the conditions will
only apply to a form or report. I am looking for any help or suggestions.

Thank you.

Steve Schapel


"look at a table" doesn't really make sense, unless you specify which record
in the table.

If you mean to go ahead with the macro if *any* records in the table meet
your criteria, then enter the macro Condition like this:
DCount("*","UPDATE","[Date]=Date() And [Update Status]='Yes'")>0

By the way, as an aside, 'date' is a Reserved Word (i.e. has a special
meaning) in Access, and should not be used as the name of a field or

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question