How to merge the two cells of a table in a Google text Document without this weird result?

[edit to address updates in Google Docs] This currently not possible. You can know if a cell is merged by looking calling getColSpan and getRowSpan but there are no setter methods. Please star the following issue to be notified by updates regarding this. The merge function you found is not specific to table cells, it … Read more

Create a post in Blogger with Google Apps Script

Required reading: ScriptApp#getOauthToken Blogger §post#insert UrlFetchApp#fetch Editing manifest#Setting explicit scopes Switch to standard GCP API Library Issue: Usage of asynchronous client side browser samples in the synchronous server side. Solution: It is possible to access Blogger api from Google apps script using UrlFetchApp Full OAuth flow can be bypassed using oauth token provided by ScriptApp … Read more

Copying a spreadsheet copies all linked files as well

How about this workaround? In this workaround, Sheets API is used for copying a Spreadsheet. In the case of copy() of Class Spreadsheet, makeCopy() of Class File and Files: copy of Drive API, the copied spreadsheet includes the bound scripts and linked forms. So I thought to use Sheets API. The flow of this workaround … Read more

Why does google script editor stop paren matching after 100 lines in a function and does it affect the code?

I’ve tried this myself, and reproduced your results, using Chrome on Windows Vista. The paren matching went Red with exactly 100 blank lines between the opening and closing braces. Steps to try, for the non-believers: In Drive / Docs, create a new script for a blank project. Start with the template for “myFunction()”. Place the … Read more

File movement between Google Shared Drive (team drive) folders using Apps Script

Okay looks like I found an answer, via REST API I can update file’s parents. I’ve made that call and it’s working. Here’s the sample. var apiUrl = “https://www.googleapis.com/drive/v3/files/fileId?addParents=newFolderId&removeParents=oldFolderId&supportsTeamDrives=true”; var token = ScriptApp.getOAuthToken(); var header = {“Authorization”:”Bearer ” + token}; var options = { “method”:”PATCH”, “headers”: header }; var res = UrlFetchApp.fetch(apiUrl, options); UPDATE Using … Read more

Single Google Form for multiple Sheets [duplicate]

Step 1: Create Form Normal operating procedure – create your form either through a script or using the Forms UI. Capture the ID of the form. For instance, from the URL when in the editor: https://docs.google.com/forms/d/1-AWccGNgdJ7_5Isjer5K816UKNSaUPSlvlkY3dGJ1UQ/edit ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Attach a spreadsheet to capture responses. (We’re not going to do anything more with that here.) Step 2: … Read more