entering date/time in 1/4 or 1/2 hour increments?

D

David

Does anyone have a suggestion or template with easiest way to enter date/time
in excel for keeping track of project times by the hour?
ie. drafting log or simple work log but in hours and not simply days...
Thanks,
David
 
J

Jim May

Format A1 containing Date and Time and enter 8/27/2007 8:00 AM
in Cell B1 enter =A1+(1/48) '48 for 1/2 hour use 24 for 1 hour
 
D

David

Jim,
Thanks for the suggestion but I need to find a way or template that has an
easy way to insert date & time like the shortcut ctrl :
but only in 15 minnute increments from the actual time. ie 1/4 or 1/2 hour
increments.

I do a lot of project work and would like to be able to post it quickly in a
log.
my window of available hours is 7:00 am to 7:00 pm.
If someone has a drop down list template or I'll make my own, this might
work easy enough.
 
S

Sandy Mann

Use the event Macro:

Private Sub Worksheet_Change(ByVal Target As Excel.Range)
If Intersect(Target, Columns("A:A")) Is Nothing Then Exit Sub
'Change Columns to your Required column
If Target.Rows.Count > 1 Then Exit Sub

Application.EnableEvents = False
Target.Value2 = Int(Target.Value2 * 96 + 0.5) / 96
Application.EnableEvents = True
End Sub
--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

[email protected]
Replace @mailinator.com with @tiscali.co.uk
 
D

David

Sandy,
Do you have a small sample template with the macro built in it?
It has been a while since I used or made a macro.
Thanks,
David
 
S

Sandy Mann

David,

Send me a private e-mail so that I can get your address and I will send you
a sample workbook - do NOT post your real email address here or you will be
targeted by the spambots.

Alter my e-mail address below by replacing the @mailinator.com as it says
because Mailinator is a spam trap that creates an account for you
automatically on receipt of a e-mail and delates it again "after a few
hours"
--
Regards,

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

[email protected]
Replace @mailinator.com with @tiscali.co.uk
 
Top