comparing 2 fields

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,
I'm trying to write a macro that compares 2 addresses to see if they are the
same or not. We generate letters and do not want to send the same letter to
the same address. If the address is the same, I want a message box to appear
telling them that they already sent a letter like that to that address. If
the address is different, I want it to go through and be processed.

Help!
DMW
 
One is a table with client's information and 1 in a table that houses letters
sent. I have a form that our employees bring up to request a letter. It
shows letters sent but that doesn't prevent a person who's not paying
attention from requesting the same letter at the same address again. I'd
like to have it catch that so the same letter doesn't go out no matter what.
I've had it happen before so I'd like it to be as idiot-proof as possible.
If it helps, it's for a collection agency.
 
A macro can run a query (unmatched) but I do not see how you can do it with a
macro alone.
 
DMW,

In theory, you could use a DLookup() function to see if the specified
address is already exists in the letters sent table. But in practice,
this might be a problem, depending on how the data is getting into the
tables in the first place, as addresses are notorious for the
inconsistencies and inaccuracies of data entry.
 
Back
Top