1
votes

I have a google form that gets generic information from the user and saves it all in a sheet. When a new form is submitted, the information is appended together with a new line (\n) command between every new piece of information, and is sent to an email using the Mailapp.sendEmail(email, subject, message) function. This works fine, and is formatted the way I would like it. However, when I use the Mailapp.sendEmail(email, replyEmail, subject, message) function, the \n commands seem to disappear from the code. They do not show up in the email and the information in the email is all grouped together in 1 line. Does anyone know why this might be happening, and how I would be able to get the formatting back? Thanks!

1

1 Answers

1
votes

The email is formatted as html. If you change your '\n' to '<br>' it will break the lines.

This was my test:

MailApp.sendEmail("[email protected]","[email protected]" , "Subject", "This<br>Is<br>The<br>Body");