summaryrefslogtreecommitdiffhomepage
path: root/examples
diff options
context:
space:
mode:
authorJonathan Tron <[email protected]>2015-07-04 11:30:42 +0200
committerJonathan Tron <[email protected]>2015-07-04 11:30:42 +0200
commit69bcb479a3a3f279a8f395e02f7191ba2bd4152d (patch)
tree57ddb123fa52320176c05b92c12b23cf650813af /examples
parent5a343241ed5ae7226ce691256118e51b44c60f87 (diff)
parenta1006751413997ff5be88bd1321859d2f5dd566c (diff)
downloadcaxlsx-69bcb479a3a3f279a8f395e02f7191ba2bd4152d.tar.gz
caxlsx-69bcb479a3a3f279a8f395e02f7191ba2bd4152d.zip
Merge branch 'worksheet_tab_colour' of https://github.com/shifakhan/axlsx into shifakhan-worksheet_tab_colour
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/example.rb12
1 files changed, 12 insertions, 0 deletions
diff --git a/examples/example.rb b/examples/example.rb
index 15d34ed6..fb4fc924 100755
--- a/examples/example.rb
+++ b/examples/example.rb
@@ -51,6 +51,7 @@ examples << :no_autowidth
examples << :cached_formula
examples << :page_breaks
examples << :rich_text
+examples << :tab_color
p = Axlsx::Package.new
wb = p.workbook
@@ -843,3 +844,14 @@ if examples.include? :rich_text
p.serialize 'rich_text.xlsx'
end
#```
+
+##Change tab color of sheet
+
+#```ruby
+if examples.include? :tab_color
+ wb.add_worksheet(:name => "Change Tab Color") do |sheet|
+ sheet.add_row ["Check", "out", "the", "Tab Color", "below!"]
+ sheet.sheet_pr.tab_color = "FFFF6666"
+ end
+end
+##``` \ No newline at end of file