Sha256: 73c028af347fb78bed4e8180279b841959b903ff53da9c7af535d3fbd9218b55

Contents?: true

Size: 769 Bytes

Versions: 1

Compression:

Stored size: 769 Bytes

Contents

#!/usr/bin/ruby -w

#######################################################################
#
# Example of how to hide a worksheet with Spreadsheet::WriteExcel.
#
# reverse('©'), April 2005, John McNamara, jmcnamara@cpan.org
#
# original written in Perl by John McNamara
# converted to Ruby by Hideo Nakamura, cxn03651@msj.biglobe.ne.jp
#
require 'rubygems'
require 'writeexcel'


workbook   = Spreadsheet::WriteExcel.new('hidden.xls')
worksheet1 = workbook.add_worksheet
worksheet2 = workbook.add_worksheet
worksheet3 = workbook.add_worksheet

# Sheet2 won't be visible until it is unhidden in Excel.
worksheet2.hide

worksheet1.write(0, 0, 'Sheet2 is hidden')
worksheet2.write(0, 0, 'How did you find me?')
worksheet3.write(0, 0, 'Sheet2 is hidden')

workbook.close

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
writeexcel-0.1.0 examples/hidden.rb