From 709ca2e41edf9df5e5a168d3f05f23ea79aa75ad Mon Sep 17 00:00:00 2001 From: Bryan Date: Thu, 16 Nov 2017 00:00:40 -0600 Subject: [PATCH] Add recalc parameter to ImportJSON() This recalc parameter will allow a field to be changed so that the imports will be re-loaded. --- ImportJSON.gs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ImportJSON.gs b/ImportJSON.gs index fd2a671..712442b 100644 --- a/ImportJSON.gs +++ b/ImportJSON.gs @@ -64,7 +64,7 @@ * * @return a two-dimensional array containing the data, with the first row containing headers **/ -function ImportJSON(url, query, parseOptions) { +function ImportJSON(url, query, parseOptions, recalc) { return ImportJSONAdvanced(url, null, query, parseOptions, includeXPath_, defaultTransform_); } @@ -104,6 +104,7 @@ function ImportJSON(url, query, parseOptions) { * @param {fetchOptions} a comma-separated list of options used to retrieve the JSON feed from the URL * @param {query} a comma-separated list of paths to import. Any path starting with one of these paths gets imported. * @param {parseOptions} a comma-separated list of options that alter processing of the data + * @param {recalc} [optional] a cell reference that allows the ImportJSON() to be re-loaded when changed. * @customfunction * * @return a two-dimensional array containing the data, with the first row containing headers