Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

135
Views
Elimine la fila en la hoja de Google a través de los scripts de la aplicación si las columnas cumplen con los criterios

Quiero poder eliminar una fila si ciertas columnas coinciden con los criterios. Esto es lo que tengo hasta ahora:

 function deleteEachRow(){ let tempSheet = SpreadsheetApp.getActiveSpreadsheet(); let sheet = tempSheet.getSheetByName("Intermediate"); var RANGE = sheet.getDataRange(); var rangeVals = RANGE.getValues(); }

desde aquí me gustaría saber si la columna [11] !=='' y la columna [12] === 'completada', si cumple con los criterios, elimine la fila.

¿Algunas ideas?

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

function deleteEachRow(){ const ss = SpreadsheetApp.getActiveSpreadsheet(); const sh = ss.getSheetByName("Intermediate"); const sr = 2;//data start row const rg = sh.getRange(sr, 1, sh.getLastRow() - sr + 1, sh.getLastColumn()); const vs = rg.getValues(); let d = 0; vs.forEach((r,i) => { if(r[10] && r[11] == 'completed') {//column 11 and 12 sh.deleteRow(i + sr - d++);//d increments on each delete } }); }
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!