Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How do I create a formula to add hours to a mm/dd/yy h:mm format c

I wish to create a tide predictor. I have the stated date/time for High and
Low tide. I wiould like to create a formula to add/subtract hours based on
different locations in the region.

Ft. Mchenry - High Tide 7/01/2008 01:20
new location Sandy Pt. is Ft Mchenry High Tide plus 2 hours (should equal
7/01/2008 03:20)
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 18
Default How do I create a formula to add hours to a mm/dd/yy h:mm format c

Just add 0.0416666666 to the value of Ft. Mchenry

formated as number:
39672,0000000000
39672,0416666666

formated as date/time
12.08.2008 00:00
12.08.2008 01:00



"bm05" wrote:

I wish to create a tide predictor. I have the stated date/time for High and
Low tide. I wiould like to create a formula to add/subtract hours based on
different locations in the region.

Ft. Mchenry - High Tide 7/01/2008 01:20
new location Sandy Pt. is Ft Mchenry High Tide plus 2 hours (should equal
7/01/2008 03:20)

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,600
Default How do I create a formula to add hours to a mm/dd/yy h:mm format c

Sub test()
Dim dt1 As Date, dt2 As Date
dt1 = DateSerial(2008, 7, 1) + TimeSerial(1, 20, 0) 'y,m,d + h,m,s

dt2 = dt1 + TimeSerial(2, 0, 0)

MsgBox Format(dt1, "mmm/d/yy h:m") & vbCr & _
Format(dt2, "mmm/d/yy h:m")

End Sub



"bm05" wrote in message
...
I wish to create a tide predictor. I have the stated date/time for High

and
Low tide. I wiould like to create a formula to add/subtract hours based

on
different locations in the region.

Ft. Mchenry - High Tide 7/01/2008 01:20
new location Sandy Pt. is Ft Mchenry High Tide plus 2 hours (should equal
7/01/2008 03:20)



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
CREATE A FORMULA FOR HOURS WORKED THAT SUBTRACTS LUNCH Mrs Boyd Excel Worksheet Functions 3 February 16th 10 07:29 PM
create a formula to muliply hours times dollars per hour? sirrafs Excel Discussion (Misc queries) 1 September 14th 06 05:15 AM
how do I create formula to sum hours & min's Susan Excel Worksheet Functions 4 August 22nd 06 11:26 PM
Create a formula using cell format CMagras Excel Discussion (Misc queries) 2 May 10th 06 03:37 PM
Convert hours and minutes in time format into fractions of hours.. Akern Excel Worksheet Functions 4 April 21st 05 02:56 PM


All times are GMT +1. The time now is 07:55 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"