3 Replies Latest reply on Aug 18, 2016 1:08 PM by taylorsharpe

    Set $mailinglist variable and send one mail to all

    cillion

      Hi there!

      Am making a mail aktivity in a filemaker database that will able the users to choose peoples and send an mail to all. Am doing this with a loop thru the records choosen and set an $mailinglist variable. It it possible to expand the content of this variable if any? So I can use this variable as an full mailing list in the mail step? So I dont need to loop the mail step for every selected person?

       

      This is the section in my script where the magic will happen :

      2016-08-18_15-44-03.jpg

        • 1. Re: Set $mailinglist variable and send one mail to all
          taylorsharpe

          From above it looks like you're stringing a whole bunch of emails together and going to send a single email with all of the emails in the Email To.  That means everyone sees everyone's email unless you put them in the BCC, but then your emails will often show up as spam and get your emails rejected by many.  But if you go this way, make sure to separate each email by a comma and a space. 

           

          You can send a separate email with each loop individually and will be less likely to be marked as spam.  Also recipients won't see each others emails if you send emails separately. 

           

          If you use a plugin like 360Works Email plugin, you can send the email subject/body to the server and a list of emails to send it to in one smtp connect.  That will make things go much faster if that is what you are looking for.  Actually, most all plugins perform faster than the built in FileMaker email script step.  Also most other plugins support HTML email and multiple attachment which FileMaker for some reason still does not. 

           

          There is a whole other discussion that talks about various ways to send email that you might find interesting, including sending emails via an API:  html via send mail smtp

          • 2. Re: Set $mailinglist variable and send one mail to all
            cillion

            ok, I have not think about that as a possible downside. I thought maybe the smtp server would not allow one sender to send for example 50 identical individually emails in one bundle?! Woundt that look like spam?

             

            But anyway, I take your suggestion and send individually emails in my loop. Do you have some recommendation on how to let a user to fill out a form for some text/picture/attachments before th sending email loop? Am registering the activityhistory now in a table but not exacly what was sent in the email-activity.

             

            Own email-layout and a pop-up-window in the script?

            • 3. Re: Set $mailinglist variable and send one mail to all
              taylorsharpe

              I like sending individual emails and customizing the message such as "Dear John:...." and maybe some specific information about them.  The more customized each email, the less likely it will be marked as spam. 

               

              You can always do a "Show Custom Dialog Box", but it only shows a small amount of space to type.  So I would take them to a popover or slider or even another layout that has a big field to allow them to free form type a longer message.  You can then send the email using the data in that field.  But yes you can have user intervention to modify the body of the message if you want. 

              1 of 1 people found this helpful