From: Serguei Cambour Date: 2010-03-10T23:11:00+09:00 Subject: Re: Float in Spreadsheet I found a solution. To avoid leading zeros, you have to set the frmat as follows: nb_format = Spreadsheet::Format.new :number_format => '#,###' sheet1.row(4).set_format(0, nb_format) What is important - the rounding is made out of the box (1500.78 will be formatted as 1,501, 0 will be formatted as empty cell) so no need to write something else :) -- Posted via http://www.ruby-forum.com/.