I made a similar request a few days ago using the following link:
How to copy a specific row from one sheet to another (Google Apps Script)
Now I have new requirements for which I need your help:
the script should copy specific rows that have value "No" in column T from one sheet to another sheet. It is important that it copies the values and the formatting.
the complete row should be copied.
after successful copying, the row should be deleted in the sourcesheet.
Can you please help me? Thank you very much!
Below you can find @Marios solution so far. At this point again many thanks!
const ss = SpreadsheetApp.getActiveSpreadsheet();
const srcSheet = ss.getSheetByName("[Overview] All_Cases");
const tarSheet = ss.getSheetByName("OPS_FUNNEL");
const data = srcSheet.getDataRange().getValues().filter(r=>r[21]=='No').map(r => [r[0]]);
var tarlast = tarSheet.getRange("A:A").getValues().filter(String).length;
if (data.length>0){
tarSheet.getRange(tarlast+1,1,data.length,1).setValues(data);
}