batch-request

How to use conditional formatting in Google sheets api v4

倾然丶 夕夏残阳落幕 提交于 2021-02-11 12:30:01
问题 Good day. Please tell me how I can convert this script to use Google sheets api v4 and reduce the cost of the request. Understand correctly that I need to dig to the side: https://developers.google.com/sheets/api/samples/conditional-formatting?hl=en#add_a_conditional_formatting_rule_to_a_set_of_ranges ? Sample code below while (folders.hasNext()) { var folder = folders.next().getId(); var sheet1 = SpreadsheetApp.openById(folder); var sheet = sheet1.getActiveSheet(); var r1 = sheet.getRange(

Is it possible to further reduce the cost of the request with Google sheets api v4 in setValue and setNumberFormat?

这一生的挚爱 提交于 2021-01-28 21:28:44
问题 Now I use the code below to format and insert values. function AddName () { const range1 = ['Q4:Q','S4:S','U4:U','W4:W','Y4:Y','AA4:AA','AC4:AC','AE4:AE', 'AG4:AG','AI4:AI','AK4:AK','AM4:AM','AO4:AO','AQ4:AQ','AS4:AS','AU4:AU','AW4:AW','AY4:AY','BA4:BA', 'BC4:BC','BE4:BE','BG4:BG','BI4:BI','BK4:BK','BM4:BM','BO4:BO','BQ4:BQ','BS4:BS','BU4:BU','BW4:BW', 'BY4:BY','CA4:CA','CC4:CC','CE4:CE','CG4:CG','CI4:CI','CK4:CK','CM4:CM','CO4:CO','CQ4:CQ','CS4:CS', 'CU4:CU','CW4:CW','CY4:CY','DA4:DA','DC4