removeColWidths: Remove column widths from a worksheet

View source: R/wrappers.R

removeColWidthsR Documentation

Remove column widths from a worksheet

Description

Remove column widths from a worksheet

Usage

removeColWidths(wb, sheet, cols)

Arguments

wb

A workbook object

sheet

A name or index of a worksheet

cols

Indices of columns to remove custom width (if any) from.

Author(s)

Alexander Walker

See Also

setColWidths()

Examples

## Create a new workbook
wb <- loadWorkbook(file = system.file("extdata", "loadExample.xlsx", package = "openxlsx"))

## remove column widths in columns 1 to 20
removeColWidths(wb, 1, cols = 1:20)
## Not run: 
saveWorkbook(wb, "removeColWidthsExample.xlsx", overwrite = TRUE)

## End(Not run)

openxlsx documentation built on Sept. 20, 2024, 5:08 p.m.