Calulate date?

  • Thread starter Thread starter Scott Smith
  • Start date Start date
S

Scott Smith

When I send a mailing to a prospect, I log a journal entry associated
with the contact. I also have a user-defined field called "Mailing
Frequency" in a custom form. (It is an integer specifying days
between mailings.)

In a contact view, custom form, or something, I need to do the
following:
For each contact, find the last entry type containing the word
"Mailed", extract its date, add the "Mailing Frequency" value to it,
and calculate the next mailing date.

(Ultimately, I would like to sort contacts by this calculated 'Next
mailing date' for doing a mail merge.)

Any help getting me started would be appreciated
 
You can actually do this without VBA. First, create a view in your Contacts
folder that filters for items containing "Mailed". Then, create a custom
field for that view called "Next Mailing" or something. Make sure that you
choose 'formula' as the type. For the formula itself, use this:

DateAdd("d",[Mailing Frequency],[Created])

Where 'Mailing Frequency' is the name of your existing custom field. This
should do it!
 
Eric-

That's a great idea! Thanks! I had never seen the 'formula' option for
fields in Outlook.

One possible kink though. If I understand correctly, your solution will
cycle every 'X' days after the day the contact was created. I was
hoping to have the item scheduled relative to the last mailing event in
the journal. Is this possible?

I'm thinking that maybe I could change my ways to make your solution
work, but I'd prefer that it work as I describe...

Thanks again!

Scott
 
Unfortunately, there's no way to use formulas to lookup information in
another item. You would need to add some code behind your custom contact
form to lookup the related journal items, find the last mailing event, and
put that in a custom field in the form/folder. It's not impossible, but
more involved.

Eric
 
Back
Top