Hi All,

when using 

-- cut --

    number_style <- openxlsx::createStyle(
      numFmt = "COMMA"
    )

    openxlsx::addStyle(
      wb = xlsx_workbook,
      sheet = "Kundenliste",
      style = number_style,
      rows = 2:nrow(customer_list),
      cols = 4:5
      )
--cut --

I get the error

Error in openxlsx::addStyle(wb = xlsx_workbook, sheet = "Kundenliste",  : 
  Length of rows and cols must be equal.

The customer_list can be of any arbritrary length due to subgroup 
definitons. I do not see why the argument "rows" and "cols" should be of 
the same length. This would mean that number formatting can only be done 
for rectangular areas.

What do I need to change to format my numbers in the given area correctly?

Kind regards

Georg

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to