From: Steve Tuckner Date: 2002-08-17T01:21:30+09:00 Subject: RE: file edit fout = File.new("file2.ps") linenum = 1 File.open("file.ps") do |f| f.each_line do |l| if linenum == 3 then # change line end fout.puts l linenum += 1 end end fout.close -----Original Message----- From: Nick Massaro [mailto:nmassaro@co.jefferson.co.us] Sent: Friday, August 16, 2002 11:04 AM To: ruby-talk ML Subject: file edit I have a 40meg postscript file that I need to change the header on. Is it possible to change the third line/xxx charactor without loading the entire file into an array.