Call up several books and clean their contents

Viero
New Member

Hello,
I am making a code to create a function that at the moment of pressing a button, exports the information of several books to a PDF and once finished, it deletes the data of some specific cells, however to make the call of those books I need to call it via URL, but it wonโ€™t let me call them, just doing them 1 by 1 and thatโ€™s very tedious โ€ฆ I donโ€™t know if Iโ€™ll have to call them via URL
I leave the code that I am using where the โ€œopenBy URL ()โ€ is where I must place the addresses of several books โ€ฆ
function clear_sheeds(){

var Activ = SpreadsheetApp.openByUrl(โ€œCaptura4 - Google Sheetsโ€);

var uf = Activ.getLastRow();

var cel = Activ.getRange(โ€œC11:Cโ€).clearContent();

var cel2 = Activ.getRange(โ€œF11:Fโ€).clearContent();

}

0 2 103
2 REPLIES 2

This appears to be a question about a Google App Script, and has nothing to do with Appsheet, correct?

Iโ€™ll try to answer your question, but just know that this is the Appsheet community and typically you wonโ€™t find much support for GAS here.

You probably should hold an array of all of the URLs, then run a loop over that array, calling your posted function on every iteration, passing each individual URL.

Viero
New Member

Thank you very much for your support!
Iโ€™ll tryโ€ฆ

Top Labels in this Space