Hello everyone, I am looking for some advice. This is my current script, it works great, unfortunately now my Excel files is too large and fails when ran through Power Automate, and I am coming up with
Range getCell: The request payload size has exceeded the limit.
How can I take this and adjust it for 30K rows?
function main(workbook: ExcelScript.Workbook) {
const currentSheet = workbook.getActiveWorksheet();
const usedRange = currentSheet.getUsedRange();
let values = usedRange.getValues();
let rowCount = usedRange.getRowCount();
for (let i = rowCount - 1; i >= 0; i--) {
if (
values[i][11] == "red" ||
values[i][11] == "blue" ||
values[i][11] == "green") {
usedRange.getCell(i, 1).getEntireRow().delete(ExcelScript.DeleteShiftDirection.up)
}
}}