From: Glen Holcomb Date: 2007-05-15T04:57:04+09:00 Subject: Re: Time range help ------=_Part_157700_17698628.1179172607887 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Does it have to be a time object? Date has some methods that will do what you want without much if any hassle. On 5/14/07, Mike Hamilton wrote: > > I have 2 time objects and want to iterate over them by day. I figured > out that I can do: > a = Time.mktime(2007,5,1,0,0,0) > b = Time.mktime(2007,5,7,0,0,0) > (a..b).each { |val| > code goes here > } > but when I do that it iterates over seconds. Does anyone have a > suggestion on how to iterate over a different period when using Time > objects? > > -- > Posted via http://www.ruby-forum.com/. > > -- "Hey brother christian with your high and mighty errand, Your actions speak so loud, I can't hear a word you're saying." -Greg Graffin (Bad Religion) ------=_Part_157700_17698628.1179172607887--