Thank you for your suggestions @GOS. For my specific situation the other options without Sendgrid are not suitable. I watched all your suggestions and it’s exactly the same as the codes I added (Also the same setup as my first form codes). Still it’s not working. My page code is as below:
import {sendEmail} from ‘backend/email’ ;
$w.onReady( function () {
$w( “#dataset4” ).onAfterSave(sendFormData);
});
function sendFormData() {
const subject = New Submission **from** ${$w( "#input11" ).value};
const body = Name: ${$w( "#input8" ).value} \rEmail: ${$w( "#input9" ).value} \rSport: ${$w( "#input10" ).value} \rComments: ${$w( "#input12" ).value};
sendEmail(subject, body)
.then(response => console.log(response));
}
The backend codes are like mentioned in the tutorial. Do you know an other way how to solve this issue?
Kind regards.
Vincent