setSheetPos-methods

0th

Percentile

Setting worksheet position

Sets the position of a worksheets in a '>workbook.

Keywords
methods, utilities
Usage
# S4 method for workbook,character,numeric
setSheetPos(object,sheet,pos)
Arguments
object

The '>workbook to use

sheet

The name of the worksheet (character) whose position to set. This argument is vectorized such that the positions of multiple worksheets can be set with one method call.

pos

The position index to set for the corresponding sheet. If missing, sheets will be positioned in the order they are specified in the argument sheet.

Details

It is important to note that the worksheet positions will be applied one after the other in the order they have been specified.

See Also

'>workbook, getSheetPos, getSheets

Aliases
  • setSheetPos
  • setSheetPos-methods
  • setSheetPos,workbook,character,missing-method
  • setSheetPos,workbook,character,numeric-method
Examples
# NOT RUN {
# mtcars xlsx file from demoFiles subfolder of package XLConnect
demoExcelFile <- system.file("demoFiles/mtcars.xlsx", package = "XLConnect")

# Load workbook
wb <- loadWorkbook(demoExcelFile)

# Move the 'mtcars3' worksheet to the front
setSheetPos(wb, sheet = "mtcars3", pos = 1)
# }
Documentation reproduced from package XLConnect, version 0.2-15, License: GPL-3

Community examples

Looks like there are no examples yet.