How do I get the calculate the from time to start at 01:00 am and the to time to end 
at 00:59 am. Can you please show me how to get the date and time in the format 
mentioned below

In the last 7 days (23 Jul 2003 01:00 - 30 Jul 2003 00:59)


>> I was hoping somebody could help me. I'm trying to
>> display the date and time. This is how I want to
>> display it:
>>
>> If the current time is 10:05, I want to display the
>> time in this format:
>>
>> In the last hour (09:05 - 10:04)
>>
>> If the current time is 10:05 and the date is 30.July,
>> I want to display the date time in this format:
>>
>> In the last 24 hours (29 Jul 2003 10:00 - 30 Jul 2003
>> 09:59)
>>
>> If the current time is 10:05 and the date is 30.July,
>> I want to display the date time in this format:
>>
>> In the last 7 days (23 Jul 2003 01:00 - 30 Jul 2003
>> 00:59)
>>
>> If the current time is 10:05 and the date is 30.July,
>> I want to display the date time in this format:
>>
>> In the last 30 days (30 Jun 2003 01:00 - 30 Jul 2003
>> 00:59)
>
>Look into DateAdd() - you can add any amount of time to a date, from
>seconds to years
>
>If you want to remove 7 days, you can just do DateAdd("d", -7, Now())
>
>Hope this helps
>
>
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq

Your ad could be here. Monies from ads go to support these lists and provide more 
resources for the community. 
http://www.fusionauthority.com/ads.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to