wb <- wb_workbook() %>% wb_add_worksheet("S1") %>% wb_add_data("S1", mtcars)
wb <- wb_add_border(wb, 1, dims = "A1:K1",
left_border = NULL, right_border = NULL,
top_border = NULL, bottom_border = "double")
wb <- wb_add_border(wb, 1, dims = "A5",
left_border = "dotted", right_border = "dotted",
top_border = "hair", bottom_border = "thick")
wb <- wb_add_border(wb, 1, dims = "C2:C5")
wb <- wb_add_border(wb, 1, dims = "G2:H3")
wb <- wb_add_border(wb, 1, dims = "G12:H13",
left_color = wb_color(hex = "FF9400D3"), right_color = wb_color(hex = "FF4B0082"),
top_color = wb_color(hex = "FF0000FF"), bottom_color = wb_color(hex = "FF00FF00"))
wb <- wb_add_border(wb, 1, dims = "A20:C23")
wb <- wb_add_border(wb, 1, dims = "B12:D14",
left_color = wb_color(hex = "FFFFFF00"), right_color = wb_color(hex = "FFFF7F00"),
bottom_color = wb_color(hex = "FFFF0000"))
wb <- wb_add_border(wb, 1, dims = "D28:E28")
Run the code above in your browser using DataLab