custom-function

How to call an Apps Script library function in Google Sheet

∥☆過路亽.° 提交于 2021-02-10 22:15:52
问题 I created a Library in Google script as a standalone script with a function function1 . I published a version of this script. I also have a spreadsheet, and using a bound script, I added my library with identifier XXXX and managed to launch from scripts.google.com the function using a wrapper around function1 and logging the results : function function2() { return XXXX.function1(); } function test() { Logger.log(function2()); } The problem is I cannot call this function from a cell in the

How to call an Apps Script library function in Google Sheet

无人久伴 提交于 2021-02-10 22:13:06
问题 I created a Library in Google script as a standalone script with a function function1 . I published a version of this script. I also have a spreadsheet, and using a bound script, I added my library with identifier XXXX and managed to launch from scripts.google.com the function using a wrapper around function1 and logging the results : function function2() { return XXXX.function1(); } function test() { Logger.log(function2()); } The problem is I cannot call this function from a cell in the

how to make a custom function NOT recalculate in Google Sheet

最后都变了- 提交于 2021-02-10 15:43:45
问题 I find that each time i log in. The heavy functions I have do recalculate. IN particular it is functions including UrlFetch that recalculate and make 100s of calls to the url when I log in. I would rather just rely on the data I drew last time. Is there a way to block (haphazard) recalculation? 回答1: Thanks for Ruben's help: Function recalculation cannot be disabled. the workarounds are (1.) to make a "switch" input to the function, which while in "don't update state" would make the function

“Internal error executing the custom function” in only one of many cells using the function

不问归期 提交于 2021-02-08 11:12:40
问题 I have a custom function in my sheet which returns the color code for the font color of an inputted cell. It has been working fine for a few months, but today, one out of 61 cells using the custom function return an error saying "Internal error executing custom formula". I do not understand why this problem would exist only in this cell (it is the 6th of 61 cells with the function) nor how to fix it. The custom function follows here: function FontColor(input) { var ss = SpreadsheetApp

“Internal error executing the custom function” in only one of many cells using the function

…衆ロ難τιáo~ 提交于 2021-02-08 11:01:01
问题 I have a custom function in my sheet which returns the color code for the font color of an inputted cell. It has been working fine for a few months, but today, one out of 61 cells using the custom function return an error saying "Internal error executing custom formula". I do not understand why this problem would exist only in this cell (it is the 6th of 61 cells with the function) nor how to fix it. The custom function follows here: function FontColor(input) { var ss = SpreadsheetApp

Google Sheets: Custom function with dynamic change

筅森魡賤 提交于 2021-02-05 08:09:20
问题 I am using a custom function that keeps track of what color a cell is. But there is a problem in that this function does not update itself if the cell color changes. Cell color: function GetCellColorCode(input) { var ss = SpreadsheetApp.getActiveSpreadsheet(); var cell = ss.getRange(input); var result = cell.getBackground(); return result } Next, I found and add a script that recalculates all the formulas in the table so that they update themselves. I added trigger so that this formula runs