Clear ranges with Google Scripts.
This came up in a recent project of mine from a client, specifically they needed to clear a range, while keeping the formulas and formatting. The goal is to just clear values within the range. While solving their issue below lets look at how we got there. To begin with we need to get a range to play with.
- Get a range
let range = mySheet.getRange("A1:B8")