Google Apps Script ➡️ Utils. Allow all IMPORTRANGE formulas for a given Spreadsheet

Max Makhrov
Sep 26, 2023

Here is the Apps Script code to open access to all importrange formulas in a given Google Spreadsheet.

Importrange is used to import data from one spreadsheet to another. As Google requires you to allow access for each importrange formula manually, this script automates that process by fetching all importrange sources and sending requests to grant permission, saving time and reducing manual work. This could be particularly useful for spreadsheets with multiple importrange formulas.

Usage:

function allowImportRange() {
var res = openAllImportrangeFormulasAccess_('SPREADSHEET_ID')
console.log(res)
}

Source code is here

https://github.com/Max-Makhrov/GoogleSheets/blob/master/utils/allowImportRange.gs

Photo by Fuu J on Unsplash

~~~

This article is part of ➡️Apps Script Utils Project.

--

--