Custom email Form on a Dynamic Page

Hi Guys i am trying to install a code on a Dynamic page where it draws the Title in for the subject line of the email so that my client will know which project the inquiry is for. At the minute it is sending to the database but i cant seem to get it to send an email to me. If you can see where my mistake is please let me know!

Try

$w("#myDataset").onAfterSave( () => {   
  sendFormData();
} );

Hi Andreas, Thanks for the input but that doesn’t work as the “Contacts” database is “dataset1”. At the minute it is submitting the information to the database but not sending the email as i want it to. Is there an easier way of doing this?

Did you ever find a solution for this?