Google App Scripts Newbie Help

85 views
Skip to first unread message

Jessie Quema

unread,
Sep 30, 2023, 5:08:40 AMSep 30
to Google Apps Script Community
Hello Everone,

I am trying to create a google app script for a user form with user restrictions. The idea is to restrict users who is not a part of the distro list. The distro list will be saved in a separate google sheets. 

Either restrict or delete the response of the unauthorized user if the email address is not present on the list.

I tried several scripts using chat GPT but for some reason the script does not delete the response of the unauthorized user.

Any help will be  greatly appreciated.

Regards,
Jessie 

Keith Andersen

unread,
Sep 30, 2023, 8:38:28 AMSep 30
to google-apps-sc...@googlegroups.com
Can you elaborate how/what data is collected from the form that indicates a user status?

Can you show us the script that evaluates the data collected from the form and deleted or doesn't show the data depending on valid users input?

We need more information in order to help.

Cheers
Keith 

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-script-community/e475f5d0-4aec-4165-98c0-7adb3af0d64an%40googlegroups.com.

Brett Grear

unread,
Oct 3, 2023, 3:10:00 AMOct 3
to Google Apps Script Community
Could you add a password to the form so only people with the password can submit. Just needs a question where the validation is set to only accept a particular string and the form can't be submitted otherwise 

Keith Andersen

unread,
Oct 3, 2023, 5:28:39 PMOct 3
to google-apps-sc...@googlegroups.com
Jessie,
A script can be written to check and delete any form submissions that don't meet any criteria you set. It can be done via a time trigger or a button on the spreadsheet.

You can import the distro email list to the form response sheet. The wrote the script on that sheet to filter and delete non-distro members submissions.

To help it would be useful to see your form submission sheet. Even if you wanted to make a mock one with similar data.

Edward Wu

unread,
Oct 4, 2023, 2:37:33 PMOct 4
to google-apps-sc...@googlegroups.com
You could probably do this in Google Sheets itself if you don't want to mess with coding.

e.g. you could create a new "valid responses" tab and do something like =query(responses!A:Z,"Select * where A = 'va...@domain.com'",1) and effectively ignore non-valid responses.


On Tue, Oct 3, 2023 at 2:28 PM Keith Andersen <keith.a...@gmail.com> wrote:
Jessie,
A script can be written to check and delete any form submissions that don't meet any criteria you set. It can be done via a time trigger or a button on the spreadsheet.

You can import the distro email list to the form response sheet. The wrote the script on that sheet to filter and delete non-distro members submissions.

To help it would be useful to see your form submission sheet. Even if you wanted to make a mock one with similar data.

On Tue, Oct 3, 2023, 2:10 AM Brett Grear <brett...@gmail.com> wrote:
Could you add a password to the form so only people with the password can submit. Just needs a question where the validation is set to only accept a particular string and the form can't be submitted otherwise 

On Saturday, 30 September 2023 at 13:38:28 UTC+1 Keith Andersen wrote:
Can you elaborate how/what data is collected from the form that indicates a user status?

Can you show us the script that evaluates the data collected from the form and deleted or doesn't show the data depending on valid users input?

We need more information in order to help.

Cheers
Keith 

On Sat, Sep 30, 2023, 4:08 AM Jessie Quema <jessie...@gmail.com> wrote:
Hello Everone,

I am trying to create a google app script for a user form with user restrictions. The idea is to restrict users who is not a part of the distro list. The distro list will be saved in a separate google sheets. 

Either restrict or delete the response of the unauthorized user if the email address is not present on the list.

I tried several scripts using chat GPT but for some reason the script does not delete the response of the unauthorized user.

Any help will be  greatly appreciated.

Regards,
Jessie 

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.

Keith Andersen

unread,
Oct 4, 2023, 3:10:08 PMOct 4
to google-apps-sc...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages