hi in line 7 what is the relevance of the keyword "function" which (if it is a unnamed function) is being fed the array name - can you not refer to the array itself why pass it as a parameter to "function" ?
Your work is amazing! In building upon the tutorial, is there a way to use Google Forms so people can submit their email on google forms, saved to google sheet, then allow them to automatically have access to a specific file, which you have set?
If you want to share a folder I suggest you check the documentation. Like that you'll find out how you can share a folder: developers.google.com/apps-script/reference/drive/folder
Yeah, I guess you could adapt the code as to have all emails in an array and then probably use REGEX to identify the separate email addresses. REGEX is not my forte so I personally wouldn't want to use that method. There are methods for removing access to files. Check here: developers.google.com/apps-script/reference/drive/file#removeEditor(String)
Can we run a zap to automatically run the script? I have Kajabi course that grants access to a spreadsheet to the person that purchases the course (currently adding students to the sheet manually - trying to learn how to automate this process). So I can create a zap (when student signs up in Kajabi, add data to “sharing automation” spreadsheet). I’d like to use a zap to also automatically run the script once new data is added to the “sharing automation” spreadsheet. So if someone signs up for the course in the middle of the night, I don’t need to go click a button to share the file with them. Thank you! Appreciate any insights you can offer!
This is an amazing Video. I really needed very much this script. Now I am only stacked in two steps. 1- is an error related to emailAndPermissions.forEach ... It says it is not a function. I changed it to array.from(emailAndPermissions).forEach and it seems to work but 2- When I run the script it continues to give me the Alert message " Permissions must be.... etc, etc" in the sheet. It seems like a loop. Every time I click 'ok' it reappears. Can you please help?
I would suggest you stick to the script I wrote. The error message about the permissions is trying to tell you that you are using the method and passing in the correct parameters.
Saperis, I saw another user had my same problem. email.AndPermissions.forEach is not a function. You said to him to check the variable name. It is not about the name. As I said I needed this script so I went over and over at lesst 50 times. It doesnt work for me and apparently for this other user. So, if you want to help, ok, otherwise no problem. I will find a solition
Hi I like how you explain things in your videos. Can you make a video about PMT function? I have a hard time understanding that function Please and Thank You!.
@@saperis Well, all I understand from it is that, its helpful when you are buying a house or a car. The formula is =PMT (rate, number_of_ periods, present_value, future_value).
@@ConanEdogawa24710 Well, I have no clue of that PMT formula so I better stick to making videos about things I have knowledge about: Google Workspace and Google Apps Script. 😀
Are you sure a notification is sent? The documentation doesn't mention anything about a notification being sent: developers.google.com/apps-script/reference/drive/file#addvieweremailaddress
@@saperis No. don't want to send notifications to the person being shared. Because by default of google driver, if I add any person with any permissions, Driver will send a message to the shared person.
Hi Jane. Is it possible to automatically, via code, not send a Notification to the person I share my Google doc with? I have successfully used your code shown in this video. Thank you, Saperis.
Hello ik this is totally unrelated but one quick question: I am currently trying to get some photos from my phone but it's damaged is there a way that I could sign into my original account on either Google photos or Google files to get them back?
Question, what if you have more than one FileID in column A? I tried this and it only did one file and ignored the remainder. I saw that the ForEach loop was just for the permissions list but there was no loop for the fileID list? Tried to figure it out but beyond me.
Correct, my script only expects one file ID. You would have to create adapt the script quite a bit to make it get n-amounts of file IDs and then loop over them.
@@saperis And you just fed my OCD a pet-project :) I can see where this would be useful for permission templates. Thanks for giving me something to chew on.
@@saperis Thanks for your great tool. It just save me a lot of time adding ppl in the file. Anyways, I need to share mutiple files (more than 1 ID) to different ppl, do you have any idea on how to adjust the script. Thank you
Whenever you want to create a new script you check the documentation. What methods exist? How can you use them? See here: developers.google.com/apps-script/reference
Very helpful! Thank you so much!
Very neat. The teaching style is precious. Lovin it.
Thank you! 😊
Thanks ! This is what I've been looking for. Thank you!
Great video. Keep flowing your word.
Happy to hear this video was useful!
Hi Jane. Thanks a lot. this video solves my problem. I have no experience whatsoever in scrips. I just code it now and works fine. Awesome!
hi in line 7 what is the relevance of the keyword "function" which (if it is a unnamed function) is being fed the array name - can you not refer to the array itself why pass it as a parameter to "function" ?
Your work is amazing! In building upon the tutorial, is there a way to use Google Forms so people can submit their email on google forms, saved to google sheet, then allow them to automatically have access to a specific file, which you have set?
Yes, you can create an Apps Script project to do that.
excellent video, it would help , i request you to make videos on some more advance functionality with google app script
I don't make any Apps Script videos on this channel anymore.
Great video. What if I want to share a folder?
If you want to share a folder I suggest you check the documentation. Like that you'll find out how you can share a folder: developers.google.com/apps-script/reference/drive/folder
Hello! How do I stop sending the file again from previous people whenever I send the file to new people?
Great video. What if one wants to share one file with multiple emails. Can it be customized for comma separated emails?
What about unsharing?
Yeah, I guess you could adapt the code as to have all emails in an array and then probably use REGEX to identify the separate email addresses. REGEX is not my forte so I personally wouldn't want to use that method.
There are methods for removing access to files. Check here: developers.google.com/apps-script/reference/drive/file#removeEditor(String)
Can somebody confirm if there any way to not send the notification via email when we share the file via script?
Awesome! Thank you.
You're welcome! 😀
Very helpful video. Question for you: When sharing can you also add a custom message?
The methods to set permissions don't accept a message. You would have to expand the script to send those people a message through Gmail.
Muy buen video. Nuevo suscriptor.
Gracias! Me alegra que te ha gustado este video. Tenemos muchos otro videos para aprender Google Apps Script.
What's the reason for using const instead of var in this case?
Check this video to see the difference between const and var: ua-cam.com/video/x3xZXJmb05U/v-deo.html
hello i want to put message in it too! how i can do it??
Can we run a zap to automatically run the script? I have Kajabi course that grants access to a spreadsheet to the person that purchases the course (currently adding students to the sheet manually - trying to learn how to automate this process). So I can create a zap (when student signs up in Kajabi, add data to “sharing automation” spreadsheet). I’d like to use a zap to also automatically run the script once new data is added to the “sharing automation” spreadsheet. So if someone signs up for the course in the middle of the night, I don’t need to go click a button to share the file with them.
Thank you! Appreciate any insights you can offer!
I'm assuming you are referring to using Zapier to automate the process. I know you can automate lots with Zapier, have never done so myself though.
Did you figure this out? I have pretty much the exact same issue as you
Thanks for explain this video.. can you make video share automate file to whatsapp using google appscript. Thanks before
We do not do any Apps Script videos on this channel anymore.
This is an amazing Video. I really needed very much this script. Now I am only stacked in two steps.
1- is an error related to emailAndPermissions.forEach ... It says it is not a function. I changed it to array.from(emailAndPermissions).forEach and it seems to work but
2- When I run the script it continues to give me the Alert message " Permissions must be.... etc, etc" in the sheet. It seems like a loop. Every time I click 'ok' it reappears.
Can you please help?
I would suggest you stick to the script I wrote. The error message about the permissions is trying to tell you that you are using the method and passing in the correct parameters.
Saperis, I saw another user had my same problem. email.AndPermissions.forEach is not a function. You said to him to check the variable name. It is not about the name.
As I said I needed this script so I went over and over at lesst 50 times.
It doesnt work for me and apparently for this other user.
So, if you want to help, ok, otherwise no problem. I will find a solition
Hi I like how you explain things in your videos. Can you make a video about PMT function? I have a hard time understanding that function Please and Thank You!.
What's a 'PMT function'?
@@saperis
Well, all I understand from it is that, its helpful when you are buying a house or a car. The formula is =PMT (rate, number_of_ periods, present_value, future_value).
@@ConanEdogawa24710 Well, I have no clue of that PMT formula so I better stick to making videos about things I have knowledge about: Google Workspace and Google Apps Script. 😀
Hi Saperis good day! It is posible to print a pdf file on google drive using apps script.
No, you can't print a PDF. But you can export a file and save to Google Drive as a PDF: ua-cam.com/video/xUovS4fwqsg/v-deo.html
Your video is very helpful. But I don't want to send the file sharing notification to these objects. Can you guide me?
Are you sure a notification is sent? The documentation doesn't mention anything about a notification being sent: developers.google.com/apps-script/reference/drive/file#addvieweremailaddress
@@saperis No. don't want to send notifications to the person being shared.
Because by default of google driver, if I add any person with any permissions, Driver will send a message to the shared person.
Hi Jane. Is it possible to automatically, via code, not send a Notification to the person I share my Google doc with?
I have successfully used your code shown in this video.
Thank you, Saperis.
The script in this tutorial doesn't send out any notifications to the person you are sharing the file with.
@@saperis Ok, Helen.
Thanks!
actually it sends a notification on their end.
@saperis it does send out notification, how do we disable that?
Hi, how can I have this script run automatically whenever a new entry is added? I don't want to click it every time :)
You have to add a onEdit trigger. Find out more about triggers: ua-cam.com/video/KC7pBjD3GGw/v-deo.html
Hello ik this is totally unrelated but one quick question: I am currently trying to get some photos from my phone but it's damaged is there a way that I could sign into my original account on either Google photos or Google files to get them back?
Sorry, we don't use Google Photos at all. So we have no clue if this is possible. ☹
@@saperis Ok thanks for the info
Question, what if you have more than one FileID in column A? I tried this and it only did one file and ignored the remainder. I saw that the ForEach loop was just for the permissions list but there was no loop for the fileID list? Tried to figure it out but beyond me.
Correct, my script only expects one file ID.
You would have to create adapt the script quite a bit to make it get n-amounts of file IDs and then loop over them.
@@saperis And you just fed my OCD a pet-project :) I can see where this would be useful for permission templates. Thanks for giving me something to chew on.
@@justsurfin5013 did you ever figure out how to do this?
@@saperis Thanks for your great tool. It just save me a lot of time adding ppl in the file. Anyways, I need to share mutiple files (more than 1 ID) to different ppl, do you have any idea on how to adjust the script. Thank you
@@KhanhNguyen-yq5is You could change the script so that it gets all the values in the file ID column and then iterates over them.
Great video,
I want one file one email, 2nd file 2nd email
Give idia
Whenever you want to create a new script you check the documentation. What methods exist? How can you use them?
See here: developers.google.com/apps-script/reference
Hey one doubt... Why I'm getting "TypeError: emaiAndPermissions.forEach is not a function".
I'm guessing you have a typo in your code. Did you really name your variable 'emaiAndPermissions'? Or is it 'emailAndPermissions'?