Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用“roo”gem 来读取和写入 excel 表。如何在 Ruby 中使用“roo”gem 获取 excel 表中每一行的最后一列
请给我一些建议...
您可以执行以下操作:
wb = Roo::Excelx.new 'somepath/somefile.xlsx' 1.upto(wb.last_row) do |row_index| last_column = wb.cell(row_index, wb.last_column) end
http://roo.rubyforge.org/
您可以使用上面链接中所述for的方法last_column。
for
last_column