% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/wrappers.R
\name{removeWorksheet}
\alias{removeWorksheet}
\title{Remove a worksheet from a workbook}
\usage{
removeWorksheet(wb, sheet)
}
\arguments{
\item{wb}{A workbook object}

\item{sheet}{A name or index of a worksheet}
}
\description{
Remove a worksheet from a Workbook object

Remove a worksheet from a workbook
}
\examples{
## load a workbook
wb <- loadWorkbook(file = system.file("extdata", "loadExample.xlsx", package = "openxlsx"))

## Remove sheet 2
removeWorksheet(wb, 2)

## save the modified workbook
\dontrun{
saveWorkbook(wb, "removeWorksheetExample.xlsx", overwrite = TRUE)
}
}
\author{
Alexander Walker
}
