Conditionally Insert Checkboxes
5:28
Sort Sheets
14:55
6 ай бұрын
Sort Range When New Data Entered
9:30
Highlight Cell vs Row
3:42
Жыл бұрын
VLOOKUP() Compilation
4:52
2 жыл бұрын
A Sad Day (last video)
1:39
2 жыл бұрын
Using JOIN() in QUERY()
8:42
2 жыл бұрын
Add a Datestamp on Bulk Paste
7:56
2 жыл бұрын
2-Way Sync: No Unique ID
10:57
2 жыл бұрын
2-way Sync: Non-row ID
10:03
2 жыл бұрын
2-Way Sync: Row-aligned ID
11:21
2 жыл бұрын
Custom Functions - Get Sheet Names
11:44
Move All Checked Rows
12:11
2 жыл бұрын
Running Multiple onEdit events
14:44
2 жыл бұрын
Multi-select Dropdowns
10:12
2 жыл бұрын
Пікірлер
@crispychickennugget1138
@crispychickennugget1138 Күн бұрын
Superb tutorial! What about comparing 3 sheets for duplicates? is it possible to use this formula?
@CanYenisey
@CanYenisey Күн бұрын
Thank you, @Spencer Farris! I see this is from 2021 yet still today very much relevant - and I have a ChatGPT+ subscription yet still couldn't hack this simple thing. You rock my man🤘🏻
@AngelSalazar-f6u
@AngelSalazar-f6u 5 күн бұрын
Neat tutorial!
@diallooumar3287
@diallooumar3287 5 күн бұрын
Hello i wnat o ask you a help. i want to lock the row entre entering a specifing value like " manager" then that row is locked only the person who has the access can edit in case there is mistake during the entring process. please can you help i will be happy. i alredy sent you a message in your email. Thank you
@140dc140
@140dc140 6 күн бұрын
Could you help me I'm having problems? I could send you over my test spreadsheet.
@limestar9751
@limestar9751 9 күн бұрын
Is there a way to lock drop downs with this?
@SpencerFarris
@SpencerFarris 8 күн бұрын
This locks any edits
@aremarketing9948
@aremarketing9948 9 күн бұрын
Low sound ;(
@SpencerFarris
@SpencerFarris 9 күн бұрын
Darn, it sounded fine when I recorded it. It may have lost audio quality when I moved it through the other programs. I'll probably have to re-record. Thanks for letting me know.
@SpencerFarris
@SpencerFarris 8 күн бұрын
I made a new one. Hopefully the audio comes across better kzbin.info/www/bejne/inO1nqONl6uBrNU
@TrenerZvezdnaia
@TrenerZvezdnaia 9 күн бұрын
Yesss = best!
@JacquiePershingLCSW
@JacquiePershingLCSW 10 күн бұрын
Hey there! I am using your script to get checkboxes to increment and decrement, and it works great, but I can not figure out how to get multiple groups to calculate. Please help! Columns C (+) and D (-) add and subtract Column B total. How do I add columns E, F, and G to the script? I can not figure out how to also get F and G to add and subtract Column E's Total... Script I am using... function onEdit(e){ if (!e) throw "Do not run from editor"; incrementAndDecrement(e); } function incrementAndDecrement(e){ const src = e.source.getActiveSheet(); const r = e.range; if (src.getName() != "Individual Student/Family Services" || r.columnStart < 3 || r.columnStart > 4) return; let out; if (r.columnStart == 3){ out = r.offset(0,-1); out.setValue(out.getValue()+1) } else { out = r.offset(0,-2); out.setValue(out.getValue()-1) } r.setValue("FALSE"); }
@ThomasHansen-t1i
@ThomasHansen-t1i 16 күн бұрын
Hi Spencer, great video. I am running a similar script but having issues when others are checking multiple boxes at the same time. The script ends up moving the wrong row and it seems the only way around it is checking the box one at a time. We have multiple people using the sheet and I was hoping to create a fail safe to avoid this issue. If you have any suggestions, that would be great!
@SpencerFarris
@SpencerFarris 9 күн бұрын
Did you make an installed trigger along with the simple trigger?
@Crumbsism
@Crumbsism 16 күн бұрын
Hi, not sure why but when i copied the code and only changed the location of the column for the drop down it takes the selected row and then the last row also. The only change was for the column which for me is 9 instead of 3
@Crumbsism
@Crumbsism 16 күн бұрын
Also a follow up, my data is coming from a google sheet is there a reason that the coding works if i manually type in something but if its the data from the form it does not move to the other tabs?
@SpencerFarris
@SpencerFarris 9 күн бұрын
@@Crumbsism Interesting. Can you share the spreadsheet with me?
@durcastraushun288
@durcastraushun288 20 күн бұрын
so, it only works for 1 cell, if I have 100 cells, i have to do drawings for each one and enter the code for each one
@SpencerFarris
@SpencerFarris 20 күн бұрын
Use checkboxes :) kzbin.info/www/bejne/iJekqnWFh8itfsU
@diegoortiz5931
@diegoortiz5931 21 күн бұрын
You're fire, bro
@juliajones5948
@juliajones5948 21 күн бұрын
THANK YOU!!!!!!!! This is exactly what I needed. What if you want to duplicate a whole notebook with protections?
@taraperkins5397
@taraperkins5397 21 күн бұрын
Lets say I want all of column j3-j25 what would the code be
@phoenixfeather2053
@phoenixfeather2053 24 күн бұрын
You are AMAZING! I have been copying/moving/deleting for years. This saves SOOOOOOO much time. Thank you very much!
@icyherenow
@icyherenow 26 күн бұрын
My goodness, I've been looking for this for so long. Thank you so much!
@candytordesillas687
@candytordesillas687 28 күн бұрын
Can you also make a video on how to make an onChange trigger from programmatically added entries to Google Sheets? For example entries that came in from AppSheet to Google Sheets. Thanks in advance!
@GraemeStewart-k9w
@GraemeStewart-k9w 29 күн бұрын
Thank you for the video. Is there a way to return the edited cells range with an onEdit(e) trigger when a filter is applied to the sheet?
@seawayaccounts
@seawayaccounts 29 күн бұрын
Hi Spence, could you help me, it is not working at all. I have used this: function onEdit(e){ if (e.range.rowStart <= 2 || e.range.columnStart !== 9 ) { return; } if (e.value && e.oldValue && !e.oldValue.includes(e.value)){ e.range.setValue(`${e.oldValue}, ${e.value}`); } else if (e.oldValue.includes(e.value)) { e.range.setValue(e.oldValue); } } The cells with the dropdow start in the row 2, column I. I am using the new future Dropdown, instead of Dropdown from a range. Mmmm what could be happening?
@FORYOU-wb1rx
@FORYOU-wb1rx 29 күн бұрын
Love from India (Bharat)💐👍
@meganpowell4754
@meganpowell4754 Ай бұрын
hello, I'm having a few issues with this script. One, I'd like it to just copy the row to the new sheet and not delete it from the original sheet. I removed the delete part of the script but it is still deleting the first cell in the row when it moves the data over. Also, I can't get it to copy over the cells in the row that have dropdown menus. Any advice? I have been messing around with it for awhile with no luck.
@SpencerFarris
@SpencerFarris 29 күн бұрын
Use .copyTo instead of .moveTo I'm not sure what you mean with your second question
@user-pj4oh6mx9d
@user-pj4oh6mx9d Ай бұрын
thank you!
@MCS.VEDIOS
@MCS.VEDIOS Ай бұрын
Thanks for the Video Brother 😊
@JennaWenaas-c6c
@JennaWenaas-c6c Ай бұрын
Hey Spencer, I've copied your script and am trying to adjust it for my spreadsheet. I've shared the file with you. Our team has four members, and we're tracking all our projects. Each of us has our own sheet that we use. When a project is marked as complete from the dropdown, we want it to move from the individual employee's tracking sheet to the 'Complete' sheet. Could you please let me know how to do this or take a look at the Google Sheet I shared with you? Thanks!
@SpencerFarris
@SpencerFarris Ай бұрын
Answered on the email, but to be clear clicking a dropdown and selecting the value that was already there doesn't count as an edit.
@MichelNabil
@MichelNabil Ай бұрын
Thanks, a lot for your awesome hacks excuse me, I'm beginner to scripting using google App sheet. The script in the video doesn't work when I copy and paste the cell values into the sheet I want to change. for example, when I paste lots of cells containing "M", I want them to automatically get changed to "Male" and so on... but it only happens to the first cell, not the rest in column. Also, I want to only trigger this script in a certain sheet, is there a way to do so? This is the current applied script: function onEdit(e){ if (!e) throw "Do not run from editor, the functipon runs automaticallly whenever an edit is made" autoReplaceValues(e); } function autoReplaceValues(e){ const values = ["M","F","O"]; const index = values.indexOf(e.value); if (index == -1) return; const replacments = ["Male","Female","Other"]; e.range.setValue(replacments[index]); }
@SpencerFarris
@SpencerFarris Ай бұрын
This script is written for an edit in a single cell, not mapped along an array To only use it on a certain sheet add const src = e.source.getActiveSheet(); if (src.getName() != "sheet name") return; put that before any of the actions in autoReplaceValues
@tom4tenmark729
@tom4tenmark729 Ай бұрын
Hey, first of all, thank you for your tutorial. I have one question tho. I'm a Admin for a Twitch Streamer, he wants to send out Postcards to everyone who subs 5 or more subs or subs at tier 3. The Moderators then have a google sheets in which they fill out the subs Discord ID, Twitch ID, when he subbed and so on. The Admins then text those people they've written down and change a dropdown status to "Done" for "Texted and received the Address" only Admins should change this status tho. The main problem ist, that I want Admins to have their own seperate sheet with a extra tab called "Addresses" in which we put all the Addresses down, the mods should not have access to it tho, hence why I want to connect both Google Sheets but only for the "Postcards" tab the moderators fill out in the seperate sheet. Those datas should be 2 way synced so admins receive what mods have written down and mods receive the changed status the admins applied. I tried your Script but once I run it it gives me the error: TypeError: Cannot read properties of undefined (reading 'source') Any idea of whats happening here? My code looks exactly like yours and I exchanged the two names + the ID to what my spreadheet tab is called. I added it in the Spreadsheet of the Admins, do I need to add anything to the Moderators one as well? Thank you in advance.
@SpencerFarris
@SpencerFarris Ай бұрын
Don't run it. The script relies on information from the edit which it only gets when the script runs automatically. Just make a trigger for the function.
@caitythekitten
@caitythekitten Ай бұрын
Spencer, this is hugely helpful for the task I'm trying to solve. I do have one question and it may be pretty basic: In the sheet, it looks like you do want the source name to be Incoming and the column to be 2. So why then do you use the != rather than ===? And if you want both of those to be true why use || instead of &&?
@SpencerFarris
@SpencerFarris Ай бұрын
There are two ways to approach these clauses: "If this is true then do the stuff" or "If this is false then quit" I prefer the second, it's just how I think about it and gets the script to quit faster if it's wrong. So what I'm saying is "If the sheet is not 'Incoming' then quit"
@caitythekitten
@caitythekitten Ай бұрын
@@SpencerFarris Got it. Thank you!
@VIJAYAMIRTHARAJPROMINANCE
@VIJAYAMIRTHARAJPROMINANCE Ай бұрын
Great Information...Thanks But, Who is Using this Script (triggering the Script), They Can also Edit the Protected Cells. Is there any way to Edit only by Sheet Owners Not by the Triggerers?? @spencer Awaiting for your Reply
@SpencerFarris
@SpencerFarris Ай бұрын
Yes, you need to use an Installed Trigger instead so that you can make it run as the sheet owners
@TheJSJosh
@TheJSJosh Ай бұрын
Is this outdated? Not even the first pass of this (the simple concatenation) works. Just, nothing happens with the dropdowns, other text will change, just not the dropdowns.
@SpencerFarris
@SpencerFarris Ай бұрын
I just tested on the shared spreadsheet and it worked fine
@K1LLA_KING_KONG
@K1LLA_KING_KONG Ай бұрын
I used your copy sheet, however I prefer to protect the SHEET and add exceptions. How do I modify this script for SHEET?
@SpencerFarris
@SpencerFarris Ай бұрын
I honestly need to make another video with that
@mrjp2149
@mrjp2149 Ай бұрын
You make it sound so easy. Is there an easier way 2 years later?
@SpencerFarris
@SpencerFarris Ай бұрын
I don't think so
@GorillaVape-ui4nd
@GorillaVape-ui4nd Ай бұрын
Hello. Excellente video. Unfortunately, the new sheet generated does not copy the protections. In my case, the original sheet is protected but I set exceptions in some cells. Would it be the cause of the script not to run properly?
@SpencerFarris
@SpencerFarris Ай бұрын
Yes, that's exactly why. This script is written with range protections in mind and sheet protections work completely differently. I honestly need to just make a new video about that
@AdaKetchum
@AdaKetchum Ай бұрын
Hello! Thank you for the helpful video! Is there a way to open to a range when you open a specific tab?
@SpencerFarris
@SpencerFarris Ай бұрын
No. There is no trackable event for "open sheet"
@johntelesengmec
@johntelesengmec Ай бұрын
Wow! You're a life saver, mate. Thanks! Just subscribed!
@philliprenault69
@philliprenault69 Ай бұрын
This video was great. Is there a way to apply this across more than two sheets? Right now I have tried =MATCH(A1,INDIRECT("Sheet2! & Sheet3!A:A"),0) without any luck. Or do I just need to add a rule for each sheet I'm attempting to match with? Thank you.
@SpencerFarris
@SpencerFarris Ай бұрын
Sheet2!Sheet3!A:A is clearly not a valid range. What exactly do you want? Formatting if A1 is matched on BOTH Sheet2 and Sheet3, or if it's matched on EITHER?
@philliprenault69
@philliprenault69 Ай бұрын
@@SpencerFarris if it’s matched on any. I have around 14 tabs and I’m looking to see if a name appears on multiple tabs. I feel that this is more a database solution that I’m trying to make sheets work with.
@SpencerFarris
@SpencerFarris Ай бұрын
@@philliprenault69 I would have a single MASTER sheet that brings in data from every sheet and then just check against that one
@manuelmedels2624
@manuelmedels2624 Ай бұрын
Hei i'm trying to do this now but it doesn't seem to be recognizing .range or .source. Am I missing a library or something (i haven't added any)
@SpencerFarris
@SpencerFarris Ай бұрын
No, no library or anything extra needed
@technologyhifi
@technologyhifi Ай бұрын
not working
@solidrootsflowerfarmgarden3518
@solidrootsflowerfarmgarden3518 Ай бұрын
I'm looking for help to open a couple sheets to the current week, can I email you?
@pravingorde
@pravingorde Ай бұрын
i have updating data formula in Roster sheet which is by importrage function from other sheet which i want to shift to new copy pasted sheet as formula and then their it changes value as per importrange function from other sheet... is it possible kindly please let know.. if yes then how can be done?
@JosephSalonga
@JosephSalonga 2 ай бұрын
i cannot press the run button what do you think is the problem?
@SpencerFarris
@SpencerFarris 2 ай бұрын
Best guess is it didn't save
@forgodani
@forgodani 2 ай бұрын
Man, this is life saving! Such a great tutorial... thanks!
@BaherSaid
@BaherSaid 2 ай бұрын
Great video man, this can work for abbreviations as well which is awesome, I just have a question, which trigger should I enter if I want to do the same but instead of onedit I want it to happen also on copy and paste, because right now when I paste the value nothing changes
@SpencerFarris
@SpencerFarris 2 ай бұрын
Does it not even work when you paste a single value?
@JessicaGreen-yf7yc
@JessicaGreen-yf7yc 2 ай бұрын
What di I do if it isn't running automatically?
@SpencerFarris
@SpencerFarris 2 ай бұрын
Check the executiona
@FreshSheets
@FreshSheets 2 ай бұрын
Sooo good! Would've been useful to clearly state that the row with the check box is what should be in " if (e.range.columnStart != 10 || e.value != "TRUE") return;" *modify the != value*
@SpencerFarris
@SpencerFarris 2 ай бұрын
Thanks for the feedback
@shane1063
@shane1063 2 ай бұрын
this was great. however when I tried it didn't work I'm assuming its cause I'm trying to replace an alpha numeric value with a word value. example I'm trying to replace "a1" with "cheerios"
@SpencerFarris
@SpencerFarris 2 ай бұрын
That should work fine. Paste your code?
@shane1063
@shane1063 2 ай бұрын
@@SpencerFarris function onEdit(e){ if (!e) throw "Do not run from editor, the function runs automatically whenever an edit is made" autoReplaceValues(e); } function autoReplaceValues(e){ if (e.value != "o1") return; e.range.setValue("george"); } function autoReplaceValues(e){ const values = ["o1","o2","o3","o4","o5","o6"]; const index = values.indexOf(e.value); if (index == -1) return; const replacements = ["george","dan","chris","david","james","paul"]; e.range.setValue(replacements[index]); }
@shane1063
@shane1063 2 ай бұрын
@@SpencerFarris actually hold on. i swear it wasn't working the other day. god programming is. i changed nothing now everything is fine
@SpencerFarris
@SpencerFarris 2 ай бұрын
@@shane1063 Hooray!
@Felixitously
@Felixitously 2 ай бұрын
Hugely helpful, had no idea it'd be such a pain to search up a solution for what I thought would be a common need, but your explanation was succinct and simple! Much appreciated (:
@vinicius2336SP
@vinicius2336SP 2 ай бұрын
AMAZING! Thank you so much!
@mohammedfarook5376
@mohammedfarook5376 2 ай бұрын
How to Hide Formulas In Google Sheets
@SpencerFarris
@SpencerFarris 2 ай бұрын
what?
@user-rs7tm8oi7i
@user-rs7tm8oi7i 2 ай бұрын
@spencer thank you for this excellent walk-through and script! I have it working in my Google Sheets workbook. It's all working fine, but the script executes *really* slowly. It literally takes 4-5 minutes to copy one sheet (tab) with protections. (The sheet being copied has some fairly complex formulas and a lot of individual cell protections, but still...) Do you have any tips on how I could speed up the script execution time? Thanks so much.
@SpencerFarris
@SpencerFarris 2 ай бұрын
All that has to do with your computer and Internet, and the difficult of copying the sheet itself. Oftne there isn't a way to speed it up