Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Custom Distribution List


This topic is 7283 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

I'm trying to create a custom distribution list using a button script. I have a project management database, which contains about 8 tables of data. Three of these tables contain email addresses (for the project team, clients, staff). Often, I find myself copying and pasting email addresses from each file/field in FMP into Outlook. I have never taken the time to setup email from FMP directly.

What I would like to do is to create three buttons which are accessible from the three layouts (To, CC, BCC). Essentially, the button would copy the email address from whatever field my cursor is currenty in, to an email table. This table would hold the necessary email addresses and allow me to write emails and then send them within FMP.

Because I often need to email to a list of people, I may have three email addresses in the TO and six in the CC and two in the BCC. Each situation is unique.

I have scripted the process, and can copy 1 email address, but each time I copy another email address, it overwrites the original email address (rather than append).

I've outlined the necessary steps below:

Choose Text in a field (layout 1/file 1)

Copy text to clipboard

change to layout 2 (file 2)

paste text into field (append to text already in field)

add semicolon as delimiter (if field is not empty)

return to original layout/field

Any help in what the script steps would be to append to the data already in the field (creating multiple "TO" email addresses in the distribution) would be greatly appreciated.

Cheers...kevin

Posted

Hi,

Creating three global fields for TO, CC and BCC would help you to solve the issue. Consider you have created the following three global fields (gTOEmail, gCCEmail and gBCCEmail) As you have described, clicking on the TO field should perform a script with the following script steps:

if trim(gTOEmail) = ""

gTOEmail = <<TO Email Address Field>>

else

gTOEmail = gTOEmail & ";" & <<TO Email Address Field>>

end if

Keep a similar script for the CC and BCC functions. And finally in the send mail script step, give a reference to the above three global fields.

One more suggestion: Instead of clicking the TO button 50 times to append 50 email addresses to the gTOEmail field, I would suggest keep a checkbox and select the ones to whom you want to send the emails. And then run a script to append the ones which are checked to the gTOEmail field by enclosing it in the Loop..EndLoop script step. That way the process would be really fast even if the email list is not more than five. Please ignore if you don't want to go for this.

Thanks,

--Sanjay

Posted

To simplify Sanjay's script idea,

Set Field [gTOEmail; LeftWords( gTOEmail & ";" & TOEmail; 9999 )]

This topic is 7283 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.