If there are multiple e-mail accounts, is there a method to choose a specific e-mail client for sending mail (e.g. send mail to students using a .edu account and, to others using a .net account)?
The easy way would be if you were sending email via FIlemakers inbuilt "send mail" script step.
Or you could use an email plugin, some will put an email client into filemaker, others may do what you are asking. I've never used any so you'll have to ask elsewhere about this.
On Apple I'm pretty sure that you can use an apple script to select which account the new email is being sent from.
Or - the quick and cheap way is just to display a dialog box reminding the user to change which email account they are sending from.
FMP has no control over the Email client. In most email apps the first account listed is the default. Any application using the send mail protocol will use the default account.
To specifically use an account set up the end Mail command to use SMTP instead of the email client. Now you can specify the exact account to use.
What email client on what OS? I provided a recent solution on the FMDiSC group regarding generating an email with an HTML signature through Mail (Mac) using Applescript only (no plugins), and am fairly certain you can adjust the outgoing account.
I presume that you want to send email to a particular account rather than choosing a particular email client.
If this is the case, you can use the PatternCount function to determine which email account to use in a particular situation. You would have to search each email address for the appropriate pattern. How you accomplish this will partly depend upon how you have your data structured. For example, if you have two separate email address fields in a contacts database but you wanted to only send a particular email to students who have an .edu account, you could do something like:
If [PatternCount ( EmailAddressField1 ; ".edu" ) > 0]
EmailAddressToUse = EmailAddressField1 ;
Else If [PatternCount ( EmailAddressField2 ; ".edu" ) > 0]
EmailAddressToUse = EmailAddressField2
Else EmailAddressToUse = ""
You would also need some code to eliminate those with no .edu address.
Retrieving data ...