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

\item{sheet}{The sheet name or index to remove}
}
\value{
The \code{wbWorkbook} object, invisibly.
}
\description{
Remove a worksheet from a workbook
}
\examples{
## load a workbook
wb <- wb_load(file = system.file("extdata", "openxlsx2_example.xlsx", package = "openxlsx2"))

## Remove sheet 2
wb <- wb_remove_worksheet(wb, 2)
}
