From: Horacio Sanson Date: 2009-03-18T13:23:38+09:00 Subject: Re: Convert from DateTIme to Time On Wed, Mar 18, 2009 at 7:46 AM, Guillaume Loader wrote: > Hello :) > > How can I convert from DateTIme to Time? > require "date" class DateTime def to_time Time.mktime(year, month, day, hour, min, sec) end end date = DateTime.now time = date.to_time time.class => Time Horacio > Thank you! > -- > Posted via http://www.ruby-forum.com/. > >