Комментарии:
If you're facing the error: "Cannot ready property 'namedValues' of undefined", please make sure the column name "Email" in the excel sheet, and the column name "Email Address" in the code are exactly the same. I.e. case sensitive. That should fix the error.
ОтветитьDo you have any code for mobile scaling. The mobile version is too small and have too much padding
Ответитьthank you
ОтветитьI’m getting an error on line 15 e.namedValues; not sure what to do to fix this?
ОтветитьAwesome - This was exactly what I was looking for. I did have 1 small issue. The email address column....the code has this : var email = responses['Email address'][0].trim();
I had to change it to var email = responses['Email Address'][0].trim();
(Email Address - both caps) in order to get it to work. After that change, it works great.
Also - 1 note - the document that you use for email needs to be viewable by anyone with the link.
Saved me a ton of time. Thanks again.
Wow, this is really cool. I'm going to use this for everything. I had the error listed at the top but it was a quick fix to change Email Address to Email address in Google Sheets. I also have the Payable Forms Add-on connected and it all integrated beautifully.
ОтветитьIs it possible to customize the template with data from the sheet?
ОтветитьHi, it's me again. Do you have a code that can send a specific email based on a response from the Google form? You are still a genius!!! Also, I was hoping to have heard from you about the timer email that I asked a video for.
ОтветитьhI, THE ERROR DESCRIPTION IS LIKE THIS:
TypeError: Cannot read properties of undefined (reading '0')
at onFormSubmit(Code:25:41)
Thank you Ahsan, very grateful for your heart to share your wisdom. I am running into an issue and I was hoping to get some advice when you get the chance. Pretty much, upon form submission I am seeing the execution fail. Encountering this error: "TypeError: Cannot read properties of undefined (reading 'Email address')
at onFormSubmit(code:25:24)" I saw your comments in the script to check the excel sheet to validate the email and I indeed confirmed it is formatted like the script: Email address, however, I continue to see this problem. Any idea?
"Choose which function to run" is not opening. Before that an error message came "You cannot create a trigger without a target function, please add functions to the attached script". What to do now ?
ОтветитьGreat video!
How do I fix the Error
Script function not found: onFormSubmit
I'm getting Script function not found: onFormSubmit error - just spins on the trigger page saying it can't find a function.
ОтветитьStill after 1 year this helps a lot.Thank you so much
ОтветитьThank you for this, It;s really helpful, however, I am experiencing an error code on
function onFormSubmit(e) {
var responses = e.namedValues;
var email = responses['Email address'][0].trim();
Logger.log('; responses=' + JSON.stringify(responses));
It doesn't work at all, I have corrected all Case Sensitive issues still not working.
Hi! Thank you for this. What code should I add if I want to add an image as an attachment? On form submit. I want to send a confirmation email for a webinar with a virtual background.
ОтветитьHello, great and quick video, followed the instructions but the emails are not being send, no errors in the Executions list, and also the details of the execution shows that the email was sent to the email address.
ОтветитьPinned by Code with Ahsan
@CodeWithAhsan I tried it but this is the error i got TypeError: Cannot read properties of undefined (reading '0')
at onFormSubmit(Code:25:41)
Script editor is missing now is missing in Google sheets. how to fix?
ОтветитьHi Ahsan im facing the error "TypeError: Cannont read properties of undefined' i went to the line 25 and edited, I inserted my personal email and still error
ОтветитьThank you for the video!! I got it working in no time!
I was wondering though, would there be a way to send a second (different) email a day or two later to follow up on the first?
Ahsan - - is there an easy way to send an e-mail to one person or another based upon a drop down in the form? In other words, based upon who the "owner' selected in the form, send the form info to them?
ОтветитьThis is not at all working. Namedvalues is empty. Please suggest
ОтветитьIt have any limitations? Per day auto mailing limit?
ОтветитьPlease let me know how to resolve it
ОтветитьHi Ahsan, I have deployed code.js in app script and set up trigger but in execution status is showing completed but with no logs
ОтветитьThank you so much for this.
But how can we customise it??
Thank you a lot!!
ОтветитьGreat job Ahsan, you really saved me from paying paid add-ons with this script. A well-written code with very clear documentation. I even managed to customize the email subject by adding name field from the forms.
Thanks a lot
Can I include column values from the google sheet in the email response? For instance, I have a question in my Google Form called "Area of interest" with multiple choice response values. I'd like to be able to include the selected value to this question in the email response. Thanks!!
ОтветитьWorked for me. With some few adjustments because my Google form is in french. Despite that, it works very well. Many thanks !
ОтветитьFirstly thanks for the tutorial, just that i have done the similar operations also i am getting executions after form submission, just that neither the mail is getting sent not can i find the logs which can make me sure about the message. Please help
ОтветитьHey mate! One year later, and your explanations are still top-notch! Quick question though! It appears that the emails' format is a bit weird on mobile. Any idea how to corrige that? The text is centered and appears as a column.
ОтветитьGreat work!! A flexible and simple way for creating email responses. Thank you
ОтветитьWow as smooth as butter
ОтветитьThe column name in the excel sheet and the column name in the code is same but after this its showing (namedValues) error
ОтветитьThe column name in the excel sheet and the column name in the code is same but after this its showing (namedValues) error
ОтветитьThis is amazing, and so helpful; I have been struggling for weeks with this. The only thing I can't find is how to personalise it as you mention at the end. Not a deal breaker but would have been the icing on the cake. Thanks so much.
Ответитьhi Ahsan! I don't get that option "Choose which function to run", it only shows "myFunction" there is no dropdown menu with onform submit for that first line. is there any other way to go about it?
ОтветитьService invoked too many times for one day: email.
at onFormSubmit(Code:22:11) solution?
Can you share how to customize email as i have alingment issues please help!
ОтветитьToo fast unable to understand anything
ОтветитьWhen I try to open the Apps Script from the extensions menu bar, I get the error 'sorry unable to open the file at this time' message. Please check the address and try again'. Can someone help me out here? Thanks
Ответитьthis is stil working. thank you.. 🙏🙏
ОтветитьTried it and it worked! But my google doc has images with hyperlinks. When the email is sent, the hyperlinks of the images don't work. Is there a way around this?
ОтветитьBro is there any limit of sending emails? Like per day only this much have to be send or its unlimited?
ОтветитьExcellent video! Now looking for a way to set the 'from' email address. Is it possible to set it to another gmail or other email address?
ОтветитьFor some reason, the email isn't sending. Can you help me with this?
ОтветитьGreat tool to use. thank you.
Is there a way to choose columns or fields to include in the body of the email and personalize the email with a name column from the spreadsheet? TIA