Пікірлер
@GregLawrenceAudio
@GregLawrenceAudio 10 күн бұрын
Thanks for this tutorial! It really helped me understand how to use AppScripts better and make my Google form more dynamic. I was a bit confused by your syntax when you're making the array of Form Items, with the id and name. In your forEach loop, you are placing things in a new array but since you aren't assigning that to anything, that array is not retained. I found a more efficient method to get the array shape needed by using .map(). This avoids that need for a separate splitArray() function. let items = form.getItems(); let itemIds = items.map(item => [item.getTitle(), item.getId()]);
@michadybczak4862
@michadybczak4862 21 күн бұрын
Thanks! That still works in 2024 :)
@shaunaaltman8369
@shaunaaltman8369 Ай бұрын
That’s pretty cool!
@lafamillecarrington
@lafamillecarrington 2 ай бұрын
The problem I have with this type of formula is that, because it is text, it won't sort correctly (you get row 1, then row 10 etc). I had considered using the time stamp, but it isn't very user-friendly - which is important for my use.
@dagvidar2596
@dagvidar2596 2 ай бұрын
You need to zoom in your sheets for us to see
@redtailfanschool
@redtailfanschool 2 ай бұрын
Thanks for the heads up, I'll make the adjustments next time, I appreciate the feedback
@RobKoziol
@RobKoziol 2 ай бұрын
Hi, this script seems exactly what I need however when trying to save it per your video i receive a Syntax error message as follows: Unexpected token 'const line" 6 file: Code.gs. Any idea what this means and how to overcome it? Here's my code where I've replaced the sheet name and cell Range value: What am I doing wrong? const ss = SpreadsheetApp.getActiveSpreadsheet() const ws = ss.getSheetByName ('Ofuro Product Code Generator') function resetValues() const col2 = ws.getRange('B4').setValue('Select Tub Qty')
@LionelCOSTE
@LionelCOSTE 2 ай бұрын
Amazing trick ! Thanks... Everyday you can learn something new...
@mart4144
@mart4144 2 ай бұрын
Good simple tutorial, thanks
@MrRBakhshi
@MrRBakhshi 2 ай бұрын
suppose you made your original as a powerpoint presentation, it does happen, you know added the autodate to it already, and then converted it to slides, would the autodate operate in slides?
@bricehudson9541
@bricehudson9541 3 ай бұрын
The sheets file is on the website. He stated this in the first few seconds of the video.
@CarlaArias-Chavez
@CarlaArias-Chavez 3 ай бұрын
Great formulas! I have a very similar sheet and was wondering if you had any advice on how to also calculate tardies with the timestamp?
@redtailfanschool
@redtailfanschool 2 ай бұрын
I guess if you are collecting the attendance in real time as students arrive, you could calculate a T if the timestamp was later than when they were supposed to check in. This formula would put a T if this time is after 8 am; =IF(TEXT(A2, "HH:MM") > TEXT(TIME(8, 0, 0), "HH:MM"), "T", "P")
@KaylaDarby-g7n
@KaylaDarby-g7n 3 ай бұрын
hello. do you have the formula posted anywhere? Cant read on the screen
@udayp1639
@udayp1639 4 ай бұрын
Can you emulate a Subtotal function using query function?
@redtailfanschool
@redtailfanschool 4 ай бұрын
I am not sure what you mean? It seems to me that this is basically a subtotal function. Can you be more specific?
@thecaveofthedead
@thecaveofthedead 9 күн бұрын
@@redtailfanschool this is a grand total. They're asking if you have a two layer categorisation - such as neckties | brand vs. coats | brand whether you can get a subtotal for neckties and coats the way that you can easily get from a pivot table as well as the grand total of both super categories.
@DUYENBAGWELL-e5c
@DUYENBAGWELL-e5c 4 ай бұрын
What App Script do I change to allow for check-in and check-out from devices like cell phones or laptop. When checking in/out by other users but me (the owner of the spreadsheet), it does not show time out or in. It only shows the name. The time does not populate in. What am I doing wrong?
@redtailfanschool
@redtailfanschool 4 ай бұрын
Do you mean running this sheet from a phone instead of a computer? I have not tried that, but I am not sure it will work the same, which is what you are asking I guess
@ekelly858
@ekelly858 4 ай бұрын
Excellent! Thank you!
@AbdelrahmanHussein-u7i
@AbdelrahmanHussein-u7i 4 ай бұрын
Thank you, I was at a loss until I found this video.
@andersonmenezes6374
@andersonmenezes6374 4 ай бұрын
I loved it. Congrats.
@simonjevans615
@simonjevans615 5 ай бұрын
Thank you, very useful indeed!
@andikamaulana9314
@andikamaulana9314 5 ай бұрын
Thanks dude, there is tutorial validation ID number (have 5000 row unique ID number) on input google form? if they input ID number (correct), can input google form. Sorry my english bad.
@andersonmenezes6374
@andersonmenezes6374 5 ай бұрын
I have a question. How can I do it with other pages for example 'sheet6' 'sheet7' 'shee8' in the same cell and column. col1 ('A2') for all the pages? by the way your videos are awesome. congratulations
@redtailfanschool
@redtailfanschool 4 ай бұрын
This will loop through all sheets and perform the function on all sheets if they are the same. If there are some sheets that are not set up this way, one would have to adjust the logic to not do the function on those sheets. function resetValues(){ const ss = SpreadsheetApp.getActiveSpreadsheet(); const sheets = ss.getSheets(); sheets.forEach(sheet => { sheet.getRange('A2').setValue('All Ages'); sheet.getRange('B2').setValue('All Ages'); sheet.getRange('C2').setValue('All Genders'); sheet.getRange('D2').setValue('All Pain Type'); sheet.getRange('E2').setValue('All Resting BP'); sheet.getRange('F2').setValue('All Cholesterol'); sheet.getRange('G2').setValue('All Resting ECG'); sheet.getRange('H2').setValue('All Max HR'); sheet.getRange('I2').setValue('All Exercise Angina'); sheet.getRange('J2').setValue('All Oldpeak'); sheet.getRange('K2').setValue('All ST_Slope'); }); }
@andersonmenezes6374
@andersonmenezes6374 4 ай бұрын
@@redtailfanschool Thanks a lot. You've helped, I need to learn how to use Apps Script.
@TilakConrad
@TilakConrad 6 ай бұрын
very nicely done and explained perfectly - thank you very much and the best of luck with your excellent channel
@aelengelbert
@aelengelbert 6 ай бұрын
Hola te sigo mucho y re agradezco todo lo que haces por la educación. Ojalá pudiera trabajar con usted pero vivo en Venezuela asi que como supondrá no hay recursos. Sin embargo agradezco cada video suyo éxito.
@salahuddinm06
@salahuddinm06 6 ай бұрын
Thanks a lot for esiar way.
@ekelly858
@ekelly858 6 ай бұрын
This is awesome. Thank you!
@redtailfanschool
@redtailfanschool 6 ай бұрын
Glad you liked it!
@LucaRivoira89
@LucaRivoira89 6 ай бұрын
Hello, thank you so much for your perfect guide! I have a question, if you can help me. In my form, each answer of the multiple choice item has a "go to section" information, that is going to be lost after the form is updated. Is it possible to implement the script, by updating also the "go to section" information together with the anwers? For example "go to section" information could be stored near "Form List" column. Thank you in advance!
@TilakConrad
@TilakConrad 7 ай бұрын
another superb tutorial - thanks very much - I follow you avidly 🙏 some feedback - not sure what happend to the video resolution on this.
@redtailfanschool
@redtailfanschool 6 ай бұрын
This was an older video I had made from back in 2017. So not using the same tools I currently use. Thank you for the feedback
@shawks76
@shawks76 7 ай бұрын
Great Tutorial. I'm getting a "document is inaccessible" error on this line: const copiedDocument = DocumentApp.openById(documentCopy.getId()); Any ideas? Thanks
@nancyacevedo2926
@nancyacevedo2926 7 ай бұрын
This didn't work. The copy and Paste onto google slides. Is there a script in the Google slides? Also I don't see a link to the spreadsheet.
@sunshinetorres876
@sunshinetorres876 7 ай бұрын
Hello! Would it be possible to have the ID code show at the end of the form after the submission of the form? Thank you!
@vietphulabel
@vietphulabel 8 ай бұрын
I solved the error "Exceeded maximum execution time" by this code and over 4000 files in folder listed in 1s function onOpen() { var SS = SpreadsheetApp.getActiveSpreadsheet(); var ui = SpreadsheetApp.getUi(); ui.createMenu('List Files/Folders') .addItem('List All Files and Folders', 'getListFilesandFolders') .addToUi(); }; function getListFilesandFolders(){ Logger.log("getListFilesandFolders function started"); var folderId = Browser.inputBox('Enter folder ID', Browser.Buttons.OK_CANCEL); Logger.log("Folder ID entered: " + folderId); if (folderId === "") { Browser.msgBox('Folder ID is invalid'); return; } makeListFilesAndFolders(folderId, true); } function makeListFilesAndFolders(folderId, listAll) { Logger.log("makeListFilesAndFolders function started"); const sh = SpreadsheetApp.getActiveSheet(); const range = sh.getRange('A2:H'); range.clear(); sh.appendRow(["parent", "folder", "name", "date created", "date updated", "owner", "URL", "ID"]); try { const parentFolder = DriveApp.getFolderById(folderId); Logger.log("Parent Folder ID: " + folderId); Logger.log("Parent Folder Name: " + parentFolder.getName()); listFilesAndFolders(parentFolder, parentFolder.getName(), 0); } catch (e) { Logger.log("Error in makeListFilesAndFolders: " + e.toString()); } } function listFilesAndFolders(folder, parent, depth) { const sh = SpreadsheetApp.getActiveSheet(); const data = []; const files = folder.getFiles(); while (files.hasNext()) { const file = files.next(); data.push([parent, folder.getName(), file.getName(), file.getDateCreated(), file.getLastUpdated(), file.getOwner().getEmail(), file.getUrl(), file.getId()]); } if (data.length > 0) { sh.getRange(sh.getLastRow() + 1, 1, data.length, data[0].length).setValues(data); } if (depth < 3) { // Limit recursion depth to 3 levels const subFolders = folder.getFolders(); while (subFolders.hasNext()) { const subFolder = subFolders.next(); listFilesAndFolders(subFolder, parent + "|" + subFolder.getName(), depth + 1); } } }
@dankiet4397
@dankiet4397 8 ай бұрын
If I have a folder with many sheets, can I do this? Just textformat for 2 columns
@dankiet3838
@dankiet3838 8 ай бұрын
Can you make a tutorial on how to format multiple sheet files in a folder? For example, columns B-C will be Plain-text instead of automatic
@redtailfanschool
@redtailfanschool 8 ай бұрын
I am not clear what you mean by this?
@TheShadodragoon
@TheShadodragoon 8 ай бұрын
Thank you! This is exactly what I was looking for. Keep up the good work!
@vietphulabel
@vietphulabel 8 ай бұрын
Working well for me. Thank you!
@soundinducedflow
@soundinducedflow 8 ай бұрын
Exactly what I was looking to do (less the formatting which was just some unexpected icing on the cake!) Thanks, excellent explanation!
@redtailfanschool
@redtailfanschool 8 ай бұрын
Glad it was helpful!
@soundinducedflow
@soundinducedflow 6 ай бұрын
@@redtailfanschool Very much so. PS I did notice you create a const (source) but its never used.
@cristinapajarillo6956
@cristinapajarillo6956 9 ай бұрын
Hi! Thanks for sharing! What if I have multiple email addresses, and I’d want the email sent when a cell or column contains a specific text?
@redtailfanschool
@redtailfanschool 9 ай бұрын
Yes you can! in the email field add multiple email addresses separated by commas. And I think in the script we would set it up to look for a specific text. I would have to try this to see.
@virtualassistantjelai
@virtualassistantjelai 9 ай бұрын
May I ask for a template?
@redtailfanschool
@redtailfanschool 9 ай бұрын
Surely, contact me at [email protected]
@hazamdulay6462
@hazamdulay6462 9 ай бұрын
thank you? does it work is shared drive?
@carolbaskas6929
@carolbaskas6929 9 ай бұрын
You seem super knowledgeable about this topic. I need some help...We are trying to collect information on each student every day whether or not they took and ate a school breakfast and/or lunch. I created 23 different teacher forms in which the data is being dropped into a single spreadsheet. I'm using COUNTIFS to tally. The problem I'm having is that the form is not calculating in real-time or my formulas are incorrect because I'm new at this. I was wondering if you'd be able to help me?
@redtailfanschool
@redtailfanschool 9 ай бұрын
Surely, I would be glad to help you with this project. Sorry for the late reply, I have been out of the country. Send me an email at [email protected]
@mrkhalidhafeth5823
@mrkhalidhafeth5823 9 ай бұрын
very good script
@FrankT-sz2cu
@FrankT-sz2cu 9 ай бұрын
I tried the script and it also works on shared folders. But I have a problem due to the large number of files in the folders - about 6 minutes after startup, a notification about the maximum time exceeded appears. Is it possible to amend the script so that on restart it continues where it left off in the previous attempt?
@salcoliz
@salcoliz 10 ай бұрын
Hey there, do you need to be the owner of the folder for the script to work? Thanks!
@Ruzhylkin
@Ruzhylkin 10 ай бұрын
Hello. How can this script be extended to rename files in the newly created folder? For instance to get a name structure like <student name> + <file name> Thanks.
@richardwhalen1859
@richardwhalen1859 10 ай бұрын
Thanks so much - This solved an issue for me
@aryanjha8732
@aryanjha8732 10 ай бұрын
can we do this on a third party g drive link shared with us thanks in advance
@dwccrook62
@dwccrook62 10 ай бұрын
I am trying to script using your "Use Apps Script to send a Form email to different email addresses based on a form question" video. in the for loop, I get a undefined "values" error. Does a person enter this App Scripts EXACTLY as you have it? I am new to this.
@redtailfanschool
@redtailfanschool 9 ай бұрын
So that depends on whether your sheets have the data in the exact same columns as I have. If not the script may need some modifications
@BenPomeroy-q6x
@BenPomeroy-q6x 10 ай бұрын
Thanks
@michaelreeder3106
@michaelreeder3106 11 ай бұрын
Thank you for the video. You explained it brilliantly.
@fyrman9092
@fyrman9092 11 ай бұрын
I was expecting something more complex, but your simple script was the answer to my problem. Nice Job!
@redtailfanschool
@redtailfanschool 11 ай бұрын
Glad it helped!
@vinayhompath2
@vinayhompath2 11 ай бұрын
thank you so much, you saved me hours of time adding links to my flie names in excel 🙏
@redtailfanschool
@redtailfanschool 11 ай бұрын
You're welcome!