google-app-maker

Stop AppMaker deleting email address onSend


Im just learning AppMaker and I have followed along the tutorial on sending email https://developers.google.com/appmaker/tutorials/call-scripts/

It works as expected so I decided to bring it to another level by integrating it into my sign up form.

-- ISSUE OUTLINE --

-- QUESTION --

Screenshot:


Solution

  • In the tutorial you mentioned, there is 'clearEmailForm' function that is called in case of successful sending email. I think you can delete code, that clears 'to' field:

    /**
    * Clears the entire email form
    */
    function  clearEmailForm(){
      var formWidgets = app.pages.Email.descendants;
      ...
      formWidgets.To.value = ""; // Delete this line
      ...
    }