Google email confirmation summary

12

Click here to load reader

description

A summary of how to create auto confirmation emails from a Google Form.

Transcript of Google email confirmation summary

Page 1: Google email confirmation   summary

Adam Blackwood @Adamrsc Jisc Regional Support Centre South East

Making Google Forms Send a Confirmation Email

Page 2: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 3: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 4: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 5: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 6: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script (see Slide 12 for Link to script)5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 7: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 8: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 9: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 10: Google email confirmation   summary

Quick Crib Sheet1. Create your Google Form2. Include a text field that is labelled, ‘Email

Address’3. Go to the Spreadsheet for the Form4. Copy the Email Confirmation Script5. Go to Tools Script Editor6. Paste the Email Confirmation Script into

the Script Editor7. SAVE the Script – Click the Floppy Disc icon8. RUN and INITIALISE the script

• Accept all permission requests if any appear

• DONE. – All Google Submissions will receive a confirmation email and you will receive a notification email in your gmail account.

Page 11: Google email confirmation   summary

DONE

The Script can be edited and customised for your own responses.

People making clicking on Submission will now receive a Confirmation Email.

The owner of the form will receive a confirmation email in their gmail account as well.

Page 12: Google email confirmation   summary

/* Send Confirmation Email with Google Forms */ function Initialize() { var triggers = ScriptApp.getScriptTriggers(); for (var i in triggers) { ScriptApp.deleteTrigger(triggers[i]); } ScriptApp.newTrigger("SendConfirmationMail") .forSpreadsheet(SpreadsheetApp.getActiveSpreadsheet()) .onFormSubmit() .create(); } function SendConfirmationMail(e) { try { var ss, cc, sendername, subject, columns; var message, value, textbody, sender; // This is your email address and you will be in the CC cc = Session.getActiveUser().getEmail(); // This will show up as the sender's name sendername = "Your Name Goes Here"; // Optional but change the following variable // to have a custom subject for Google Docs emails subject = "Google Form Successfully Submitted"; // This is the body of the auto-reply message = "We have received your details.<br>Thanks!<br><br>"; ss = SpreadsheetApp.getActiveSheet(); columns = ss.getRange(1, 1, 1, ss.getLastColumn()).getValues()[0]; // This is the submitter's email address sender = e.namedValues["Email Address"].toString(); // Only include form values that are not blank for ( var keys in columns ) { var key = columns[keys]; if ( e.namedValues[key] ) { message += key + ' :: '+ e.namedValues[key] + "<br />"; } } textbody = message.replace("<br>", "\n"); GmailApp.sendEmail(sender, subject, textbody, {cc: cc, name: sendername, htmlBody: message}); } catch (e) { Logger.log(e.toString()); } }

http://www.labnol.org/internet/auto-confirmation-emails/28386/

REFERENCES:…

Script and solution provided by Amit Agarwal of Digital Inspiration

Script Website…..