Search code examples
google-apps-scriptgoogle-sheetsgoogle-docsgoogle-forms

Google Form - collect username from multiple domain


I have two question as i am creating a form to collect some responses:

Q1: When creating a form using app-script, how to default the date in the google form say, tomorrow's date ?

Q2: I want to share the form to email addresses across various domains (hosted using gmail app) and want to collect the username in the response. The form is restricting me only to share and collect across a particular domain from which I have created.

Is there a way to configure with 'Require login to view this form' and 'Automatically collect respondent's email address'

I tried to search for the past 1 hour and couldn't get any useful result.

enter image description here


Solution

  • Q1: When creating a form using app-script, how to default the date in the google form say, tomorrow's date?

    You can pre-populate the responses for a Google Form by generating a "pre-filled URL" for respondents to use to open the form. For example, if the link to the form is presented on a web page, the href could be formatted with tomorrow's date as the answer to one of the questions.

    Q2: I want to share the form to email addresses across various domains (hosted using gmail app) and want to collect the username in the response. The form is restricting me only to share and collect across a particular domain from which I have created.

    That seems to be a reasonable security restriction on Google's part. You could duplicate the form in each domain, and use back-end scripting to combine results.