Compartir a través de


ExcelScript.ClearApplyTo enum

Comentarios

Ejemplos

/**
 * This script removes any extra formatting that's been applied to a table. 
 * This leaves only the base table style effects.
 * Any formatting outside of the table will be left as is.
 */
function main(workbook: ExcelScript.Workbook) {
  // Get the first table on the current worksheet.
  let worksheet = workbook.getActiveWorksheet();
  let table = worksheet.getTables()[0];

  // Get the range used by the table.
  let range = table.getRange();

  // Clear all the formatting that is not applied by the table and the table style.
  range.clear(ExcelScript.ClearApplyTo.formats);
}

Campos

all

Borra todo lo que hay en el rango.

contents

Borra el contenido del intervalo, dejando el formato intacto.

formats

Borra todo el formato del intervalo, dejando los valores intactos.

hyperlinks

Borra todos los hipervínculos, pero deja todo el contenido y el formato intactos.

removeHyperlinks

Quita los hipervínculos y el formato de la celda, pero deja intactos el contenido, los formatos condicionales y la validación de datos.