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

605
Views
Excepción: los parámetros (cadena) no coinciden con la firma del método para SpreadsheetApp.Sheet.activate

Tengo el siguiente código que funciona perfectamente como se desea... Completa todas las tareas como se esperaba, pero sigue llenando un cuadro de error rojo que me informa de una excepción. Definitivamente está completando todas las tareas, por lo que no puedo decir qué es lo que tengo mal aquí, pero ¿tal vez solo estoy usando la sintaxis incorrecta en alguna parte? Agradecería cualquier ayuda.

Mensaje de error: excepción: los parámetros (cadena) no coinciden con la firma del método para SpreadsheetApp.Sheet.activate

Aquí hay un enlace a mi hoja de ejemplo.

 function AddRoutedOptions() { var ui = SpreadsheetApp.getUi(); // Same variations. var result = ui.alert( 'Add all Routed tasks to the Project Tracker?', 'Are you sure you want to add all Routed tasks to the Project Tracker?', ui.ButtonSet.YES_NO); // Process the user's response. if (result == ui.Button.YES) { // User clicked "Yes". var pglc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Pre-Go Live Checklist'); var vcc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Video Course Checklist'); var rsc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Routed Setup Checklist').activate(); pglc.getRange('B32:B35').copyTo(pglc.getRange('E23:E26'), {contentsOnly:true}); vcc.getRange('B32:C37').copyTo(vcc.getRange('G10:H15'), {contentsOnly:true}); rsc.activate('Routed Setup Checklist'); } else { // User clicked "No" or X in the title bar. ui.alert('No tasks were added.'); } } function RemoveRoutedOptions() { var ui = SpreadsheetApp.getUi(); // Same variations. var result = ui.alert( 'Remove all Routed tasks from the Project Tracker?', 'Are you sure you want to remove all Routed tasks from the Project Tracker?', ui.ButtonSet.YES_NO); // Process the user's response. if (result == ui.Button.YES) { // User clicked "Yes". var pglc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Pre-Go Live Checklist'); var vcc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Video Course Checklist'); var rsc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Routed Setup Checklist').hideSheet(); pglc.getRange('E23:E26').clearContent(); vcc.getRange('G10:H15').clearContent(); rsc.hideSheet('Routed Setup Checklist'); } else { // User clicked "No" or X in the title bar. ui.alert('No tasks were removed.') } }
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Sheet.activate() no acepta parámetros

 rsc.activate('Routed Setup Checklist');

árbitro

Intenta cambiar esto:

 var rsc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Routed Setup Checklist').activate(); pglc.getRange('B32:B35').copyTo(pglc.getRange('E23:E26'), {contentsOnly:true}); vcc.getRange('B32:C37').copyTo(vcc.getRange('G10:H15'), {contentsOnly:true}); rsc.activate('Routed Setup Checklist');

a esto:

 var rsc = SpreadsheetApp.getActiveSpreadsheet().getSheetByName('Routed Setup Checklist'); pglc.getRange('B32:B35').copyTo(pglc.getRange('E23:E26'), {contentsOnly:true}); vcc.getRange('B32:C37').copyTo(vcc.getRange('G10:H15'), {contentsOnly:true}); rsc.activate();
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!