in macro how to determine a table is empty or number of records=0

G

Guest

The DeleteRecord command returns an error if there is on record in the
underlying table. Therefore I would like to include a condition to stop the
macro.
 
K

Ken Snell \(MVP\)

DCount("*","TableName")>0

Above expression will be true if the table has at least one record. Use this
in a Condition to run the DeleteRecord action.
 
G

Guest

Thanks a lot. Much appreciated for your help.


Ken Snell (MVP) said:
DCount("*","TableName")>0

Above expression will be true if the table has at least one record. Use this
in a Condition to run the DeleteRecord action.
 

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

Top