Help

Re: Newbie Email Button formula

531 1
cancel
Showing results for 
Search instead for 
Did you mean: 
Andy_Bowring
4 - Data Explorer
4 - Data Explorer

Hi Guys
Sorry I am still a newbie and I am having a problems setting up the new button field to send an email to a customer in my base.
I have entered the following formula

“mailto:” & ENCODE_URL_COMPONENT(Email) & “?subject=” & ENCODE_URL_COMPONENT(Subject) & “?body=“ & ENCODE_URL_COMPONENT(Body)

which gives me a problem saying

Sorry, there was a problem saving this field. Invalid formula. Please check your formula text.

My main email programme id Spark for Mac. The email address I want to send from is a Gmail address.

Please can someone let me know what I am doing wrong. Because the button field is new there is not much online to go off

2 Replies 2
Pulkit_Agrawal
4 - Data Explorer
4 - Data Explorer

Try replacing (Email) with ({name of the column or field where email is listed in your table}) and similarly for (Subject) and (Body).

I’m a noob too but this doc is helpful: https://blog.airtable.com/now-available-button-field/ and here’s a screenshot of the code they use in the gif:

Screen Shot 2020-07-23 at 15.17.48

Welcome to the community, @Pulkit_Agrawal! :grinning_face_with_big_eyes: I believe that @Andy_Bowring is already including those field names. They’re just one-word names, so they don’t require the surrounding curly braces in a formula.

To your question, @Andy_Bowring, you went a bit overboard with the URL encoding. :slightly_smiling_face: The email address itself should not be encoded. Only the subsequent items passed—subject, body, etc.—need to be encoded. By encoding the URL, the “@” turns into “%40”, rendering the email address invalid.

Edit: Sorry…I rushed a bit when I saw that encoding issue. Regarding the error, check your quotes. Make sure they’re straight quotes, not styled quotes. Airtable cares which one you use, and will only work with straight (non-styled) quotes in formulas.