google-sheets

Google Script to import CSV file from Google Drive to G Sheets when specific cell is edited

不打扰是莪最后的温柔 提交于 2021-02-11 13:03:34
问题 I have a script in my G Sheets that imports a CSV from Google Drive and I have attached it to a clickable button within the workbook. It works great. Here is the script: function myFunction() { var file = DriveApp.getFilesByName("FileName.csv").next(); var csvData = Utilities.parseCsv(file.getBlob().getDataAsString()); var sheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName("Imported File"); sheet.getRange('A1:K10000').clearContent(); sheet.getRange(1, 1, csvData.length, csvData[0]

Input cell from another sheet based on named cell name

孤人 提交于 2021-02-11 12:47:29
问题 Is they a simple way to import a cell from another sheet based on the name of a cell in the current sheet? Below, I trying to say if A2 equals named sheet say Sheet2 then import J10 from Sheet2 =IMPORTRANGE(""=A2"","J10") Thanks 回答1: Using =indirect("'"&A2&"'!J10") 来源: https://stackoverflow.com/questions/53427843/input-cell-from-another-sheet-based-on-named-cell-name

Google Apps Script uncaught error in Chrome Console

◇◆丶佛笑我妖孽 提交于 2021-02-11 12:44:50
问题 I have a simple data entry tool on my Sheet that's an HTML form and then it runs through the fields in the form and posts them to the sheet. The utility works absolutely fine on my home computer. I noticed when a colleague tried it, it failed. I checked his console and there was an uncaught error. I tried the utility on my work computer and it also failed to push the values to the sheet. Almost like there is some type of issue with the google.script.run function? I have had it work for others

calling sheet function in GAS

随声附和 提交于 2021-02-11 12:41:57
问题 Is there a way of calling sheet function in google-app-script? I want to call MATCH(), IMPORTRANGE(), and INDEX() functions to compute the return value in function definition like below. function abc(foo, bar) { a = MATCH(foo, IMPORTRANGE("address of sheet", "A:A"),0) b = MATCH(bar, IMPORTRANGE("address of sheet", "B:B"),0) return INDEX(IMPORTRANGE("address of sheet", "C:Z"),a,b) } Applying the sample provided by @Tanaike function doGet(e) { const [sheet1, sheet2, sheet3] = [e.parameter.url1,

Google Sheets: Hide rows in multiple sheets

狂风中的少年 提交于 2021-02-11 12:41:46
问题 I'm trying to hide rows across a multiple sheets. So I have a 6 sheets, but there are 4 similar sheets, the other one is more likely a summary of that 4 sheets and the other one is the sheet with a button. Here's a sample for your reference: LINK It is working if I will put a HIDE ROWS button on sheets one by one, but it will take a lot of time for me to do it since I need to put it on different spreadsheets. My idea is to put a button per spreadsheet or upon opening it, the rows that are

Google Sheets: Hide rows in multiple sheets

亡梦爱人 提交于 2021-02-11 12:41:23
问题 I'm trying to hide rows across a multiple sheets. So I have a 6 sheets, but there are 4 similar sheets, the other one is more likely a summary of that 4 sheets and the other one is the sheet with a button. Here's a sample for your reference: LINK It is working if I will put a HIDE ROWS button on sheets one by one, but it will take a lot of time for me to do it since I need to put it on different spreadsheets. My idea is to put a button per spreadsheet or upon opening it, the rows that are

Google Sheets Data Validation dropdown from single cell CSV

折月煮酒 提交于 2021-02-11 12:41:12
问题 Is there a way to create Data Validation drop-down list from a CSV string located in a single cell? I know how to create data validation drop down and manually input those items, but I want to be able to refer to a cell with the CSV string of all items to create the dropdown. Thanks. 回答1: unfortunately, this is not yet possible in Google Sheets. CSV values need to be each in a separate cell. also, formulae as range input are not supported either. 来源: https://stackoverflow.com/questions

how to print a long Goggle sheets column in fewer columns

泪湿孤枕 提交于 2021-02-11 12:20:02
问题 I have a google sheet with two long columns(image 1) of results(say 1 up to 1500 records) and column 2 I have QR codes generated by a formula. Now I need to export or print it to a pdf file, but I like to break the long columns so that the pdf file is filled with 8 columns(image 2) so that there is no paper wasted when printed. As it is, if print the page it would give me a lot of empty space. 回答1: From what I understand, you are trying to break the 1 long column into 4 columns. The following

how to print a long Goggle sheets column in fewer columns

笑着哭i 提交于 2021-02-11 12:18:06
问题 I have a google sheet with two long columns(image 1) of results(say 1 up to 1500 records) and column 2 I have QR codes generated by a formula. Now I need to export or print it to a pdf file, but I like to break the long columns so that the pdf file is filled with 8 columns(image 2) so that there is no paper wasted when printed. As it is, if print the page it would give me a lot of empty space. 回答1: From what I understand, you are trying to break the 1 long column into 4 columns. The following

Is there any way so that I can search value upwards?

泄露秘密 提交于 2021-02-11 12:08:24
问题 I was wondering if anyone knows whether it is possible or not to search a value upwards instead of the usual up to down in a column. The reason why I'm asking is because I'm currently preparing a visitor sheet which will be recorded into Google Sheets, that comes from Google Forms. Each visitor will be given an ID/Pass number which will be used to record their entry and exit time. The problem now is that, if two people uses the same ID, it will change only the entry and exit time of the