Creates a name for a specified formula in a
## S4 method for signature 'workbook' createName(object, name, formula, overwrite)
The name's name to create
Excel formula specifying the name
If a name with the same
Creates a name named
name for the specified
formula should be specified as you would type it
in Excel. Make sure that the worksheets, functions, ...
exist that you are referring to in the
overwrite arguments are
vectorized such that multiple names can be created in one method call.
Mirai Solutions GmbH https://mirai-solutions.ch
What are named regions/ranges?
How to create named regions/ranges?
## Not run: # Load workbook (create if not existing) wb <- loadWorkbook("createName.xlsx", create = TRUE) # Create a worksheet named 'mtcars' createSheet(wb, name = "mtcars") # Create a named region called 'mtcars' on the sheet called 'mtcars' createName(wb, name = "mtcars", formula = "mtcars!$A$1") # Write built-in data set 'mtcars' to the above defined named region writeNamedRegion(wb, mtcars, name = "mtcars") # Save workbook saveWorkbook(wb) # clean up file.remove("createName.xlsx") ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.