function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
J WashburnJ Washburn 

Maildrop uploads wrong address for messages in 'Sent Messages' folder.

I had a struggle with this issue and had some difficulty finding the otherwise simple solution, so here it is for the good of the order. 

 

 

Using Maildrop 2.2 on Snow Leopard 10.6.2 with Apple Mail 4.2, I was using the 'Add Email to Salesforce.com' and 'Create Case In Salesforce.com' scripts in my daily workflow. However, I noticed that whenever I tried to add an email or create a case respectively with these scripts, all was well and good if the email was in any folder but my 'Sent' folder. If the message was in this folder, the "Related to Who?" search field in Maildrop as well as the corresponding "Related to Name" field in SF had MY address, not the address of the person to whom the email was actually sent. Not optimal to say the least...

 

However the fix is easy. I am guessing that Apple made a change to what AppleScript calls the 'Sent' folder in Mail. Simon Fell, the creator of Maildrop (God bless you Simon!!!) has added a simple AppleScript to his development page (link here) which when a message in your Sent box is selected and the script is ran, reports back the name of your Sent folder as Mail sees it. Then to repair the script, one simply has to open the offending scripts in the AppleScript Editor and replace what the script is currently calling the Sent folder in each script with the correct term in one place in each script. 

 

for example, in my case:

 

The 'mailbox name.scpt' returned  "Sent Items".

 

 

thus...

 

 

for the 'Create Case in Salesforce.com' script the line:

 

if the name of theMailbox is equal to "Sent Messages" then

 

needed to be replaced with

 

if the name of theMailbox is equal to "Sent Items" then 

 

 

AND

 

for the 'Add Email to Salesforce.com' script the line:

 

if the name of theMailbox is equal to "Sent" then

 

needed to be replaced with

 

if the name of theMailbox is equal to "Sent Items" then  

 

this has solved my problems, and I hope Simon's work will solve many more!