Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Script Add Attachment won't work in OS 10.11.2 El Capitan

Featured Replies

  • Newbies

Hello,

I have this script to automate sending emails with and attachment.

For some reason in OS 10.11.2 El Capitan this script won't sent the attachment anymore.

Does anyone know the reason why.

I tried on Macs with an older system and it works?

Thanks for helping me,

Filip 

 

Campaigns: Action: Send Campaign

If [ TestForIWP ] Halt Script

End If

#

Allow User Abort [ Off ]
#
Show Custom Dialog [ Title: "Message"; Message: "Send This Campaign?¶"; Buttons: “OK”, “Cancel” ] If [ Get ( LastMessageChoice ) = 1 ]

If [ IsEmpty (Campaigns::Template_Subject & Campaigns::Template_Body) ]

Show Custom Dialog [ Message: "Please choose a template"; Buttons: “OK” ]

Go to Field [ Campaigns::Template_Subject ]

Commit Records/Requests

[ No dialog ]

Halt Script End If

#

If [ not IsValid(i_Campaign_Contacts::kf_ID_Contact) ]
Show Custom Dialog [ Message: "Please choose a recipient"; Buttons: “OK” ] Halt Script

End If

#

Go to Layout [ “Record Detail Mailings” (Campaigns) ]

#

Set Variable [ $AddAttachment; Value:Let ( [
MAC = "filemac:" & Get ( DesktopPath ) ; PC = "filewin:" & Get ( DesktopPath )

];
Case(Abs(Get ( SystemPlatform )) = 1; MAC; Abs(Get ( SystemPlatform ))= 2 ; PC ) & GetAsText ( Campaigns::Campaign_Attachment ) ) ]

If [ not IsEmpty ( Campaigns::Campaign_Attachment ) ]
Export Field Contents [ Campaigns::Campaign_Attachment; “$AddAttachment” ]

End If

#

Go to Related Record [ From table: “CampaignContacts_ContactsByID”; Using layout: “Record List Contacts” (Contacts) ] [ Show only related records ]

#

Loop
Set Field
[ Campaigns::g_ID_Contact_Temp; Contacts::k_ID_Contact ]
Go to Layout [ “Record Detail Mailings” (Campaigns) ]
Set Field [ Campaigns::g_Body_Select; Substitute ( Campaigns::Template_Body;

[ "<First Name>"; Contacts_Temp::Name_First ]; ["<Last Name>"; Contacts_Temp::Name_Last]; ["<Full Name>"; Contacts_Temp::Name_Full]; ["<Title>"; Contacts_Temp::Title];

["<Fonction>"; Contacts_Temp::Fonction];

["<Company Name>"; Contacts_Temp::Contact_Company];

["<Street>"; Contacts_Temp::Street1];

["<City>"; Contacts_Temp::City1];

["<State>"; Contacts_Temp::State_Province1];

["<Postal Code>"; Contacts_Temp::Postal_Code1];

["<Phone>"; Contacts_Temp::Phone]

)]

Send Mail [ Send via E-mail Client; To: Contacts_Temp::Email; Subject: Campaigns::Template_Subject; Message: Campaigns::g_Body_Select & Case ( IsEmpty ( Campaigns::Campaign_Attachment ); "" ; "¶" ); Attachment: “$AddAttachment” ]

[ No dialog ]

Go to Layout [ “Record List Contacts” (Contacts) ] Go to Record/Request/Page

[ Next; Exit after last ]

End Loop

#

Freeze Window

#

Set Field [ Campaigns::g_ID_Campaign_Select; Campaigns::k_ID_Campaign ]
Go to Layout [ “Mailings History Utility” (i_Campaign_History) ]
New Record/Request
Set Field
[ i_Campaign_History::kf_ID_Campaign; Campaigns::g_ID_Campaign_Select ] Go to Layout [ “Record Detail Mailings” (Campaigns) ]

#

End If

24 February 28 14:08:05

• ECB Contacts.fp7 - Send Campaign -2- 

script send mail with attachment.pdf

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.