Learn R Programming

XLConnect (version 1.1.0)

getReferenceCoordinatesForTable-methods: Querying the coordinates of the range of an Excel table

Description

Queries the coordinates of an Excel table (Office 2007+) in a workbook.

Usage

# S4 method for workbook,numeric
getReferenceCoordinatesForTable(object,sheet,table)
# S4 method for workbook,character
getReferenceCoordinatesForTable(object,sheet,table)

Arguments

object

The workbook to use

sheet

The index or name of the worksheet on which to look for the specified table

table

The name of the table to query. This argument is vectorized such that multiple tables can be queried with one method call.

Author

Martin Studer
Mirai Solutions GmbH https://mirai-solutions.ch

See Also

workbook, createName, existsName, removeName, getReferenceFormula, getReferenceCoordinatesForName

Examples

Run this code
if (FALSE) {
# mtcars xlsx file from demoFiles subfolder of package XLConnect
demoExcelFile <- system.file("demoFiles/mtcars.xlsx", package = "XLConnect")

# Load workbook
wb <- loadWorkbook(demoExcelFile)

# Query reference coordinates for table 'MtcarsTable' on sheet
# 'mtcars_table'
print(getReferenceCoordinatesForTable(wb, sheet = "mtcars_table", 
                                      table = "MtcarsTable"))
}

Run the code above in your browser using DataLab