Date and Time (entering in the format of mm/dd/yyyy and hh:mm:ss )

R

Robin

Number one I am trying to enter time and date so that there will be a lapsed
time shown.
The 1st choice is current time; Formula=NOW() the only problem is it does not show seconds. Is there any way to add seconds to this?
have Current time cell, Start time cell, and an End time cell.
to show lapsed time Example Current minus Start and End minus Start.
In the format of either mm/dd/yyyy and hh:mm:ss AM or mm/dd/yyyy and hh:mm:ss in military time.


Robin
 
F

Fred Smith

If you're looking for a solution, you need to do one of the following:
1. Keep the conversation in the same thread, or
2. If you start a new thread, then you need to a complete description of
your problem and the solution you want. No one can tell what you're looking
for from just this post.

Regards,
Fred
 
R

Robin

Thank you. I will try to restate it.

Fred Smith said:
If you're looking for a solution, you need to do one of the following:
1. Keep the conversation in the same thread, or
2. If you start a new thread, then you need to a complete description of
your problem and the solution you want. No one can tell what you're looking
for from just this post.

Regards,
Fred
 
R

Robin

I am trying to enter time and date so that there will be a lapsed
time shown.
I would like the time to be shown in the format of mm/dd/yyyy hh:mm:ss AM
or PM in a cell.
1st cell (B6) is current time =NOW() but this does not show seconds. (shows
8/13/09 18:52)
2nd cell (B7) is start time and have entered 8/1/2009 11:00:50 PM (formula
shows correct but when the cell is not clicked in it shows 8/1/2009 23:00)
3rd cell (B8) is end time and have entered 8/21/2009 11:00:58 PM (formula
shows correct but when the cell is not clicked in it shows 8/21/2009 23:00)
4th cell(B9) is Lapsed Time Current-Start entered =B6-B7 which gives value
11.82742604
5th cell(B10) is Lapsed time End - Start B8-B7 which gives a value of
20.00009259
Is there a way to adjust the formulas so that the date and time is in the
format of
mm/dd/yyyy hh:mm:ss AM or PM in a cell. Also if the Now does not show
seconds is the calculation correct for seconds.
 
R

Robin

I am trying to enter time and date so that there will be a lapsed
time shown.
I would like the time to be shown in the format of mm/dd/yyyy hh:mm:ss AM
or PM in a cell.
1st cell (B6) is current time =NOW() but this does not show seconds. (shows
8/13/09 18.52)
2nd cell (B7) is start time and have entered 8/1/2009 11:00:50 PM (formula
shows correct but when the cell is not clicked in it shows 8/1/2009 23:00)
3rd cell (B8) is end time and have entered 8/21/2009 11:00:58 PM (formula
shows correct but when the cell is not clicked in it shows 8/21/2009 23:00)
4th cell(B9) is Lapsed Time Current-Start entered =B6-B7 which gives value
11.82742604
5th cell(B10) is Lapsed time End - Start B8-B7 which gives a value of
20.00009259
Is there a way to adjust the formulas so that the date and time is in the
format of
mm/dd/yyyy hh:mm:ss AM or PM in a cell. Also if the Now does not show
seconds is the calculation correct for seconds.
 
F

Fred Smith

From what I can see, you just need to format your cells the way you want.
=now() doesn't show seconds initially, but they are there. Just change the
format to:
mm/dd/yyyy hh:mm:ss

Same with your calculation result. You likely want something like:
dd hh:mm:ss

If your elapsed time is more than 31 days, Excel won't go past that, so post
back if you need a solution for this.

Regards,
Fred
 
R

Robin

I have tried to format the cells the way that I want.
Is there a specific order that is needed to format the cells for the date
and time in mm/dd/yyyy and hh:mm:ss? I must be missing something?
So are you saying that even though they are not seen it is calculating
properly.
Why is the subtraction of current and start , and end and start represented
with a decimal instead of the true seconds?
The Days could be over 31 so I would need help with this.

Robin
 
F

Fred Smith

Let's get the formatting down first.

Enter =now() in an empty cell.
Right-click on the cell, choose Format Cells...
Based on your post, you should see
mm/dd/yyyy hh:mm
in the Type: box
Add the :ss to the format.

Does this now display the date/time the way you want?
If so, copy this format to your other cells.

Regards,
Fred
 
R

Robin

Fred, you have helped me but there is still a a problem when subtracting
date and time. It gives me a 1 in the month value when it is the same month
and there should be a 00 there. I have typed my method and following my
method I did find another example but it is only for hours.

The only thing I did differently was put it in the format of mm/dd/yy
hh:mm:ss however when I have 8/21/2009 11:00:58 PM - 8/1/2009 11:00:50 PM
Typed in the formula representing cells =B8-B7 It gives me this value for
elapsed time 01/12/00 16:45:32 there should not be a 1 in the mm value.

Fred I found this instruction in excel but do not think that it will solve
my problem.
Calculate elapsed time (subtract time)
Elapsed time is the difference between two times. Suppose that you want to
calculate the elapsed time of a practice marathon run that you started at
10:24:00 AM and that ended at 2:13:36 PM, measured to the second.

Do the following:
In cell A1 (or any other cell), type the end time. For example, type
10:24:00 AM.
In cell A2 (or any other cell), type the start time. For example, type
2:13:36 PM.
Tip Make sure that you include a space between the minute value and "AM"
or "PM."

In cell A3, type =A2-A1.
On the Home tab, in the Cells group, click Format, and then click Format
Cells.
In the Format Cells dialog box, click the Number tab.
Under Category, click Custom.
In the Type box, type [h]:mm:ss.
Tip You can also show the results in minutes by setting the format to
[m]:ss.

Click OK.
In cell A3, Excel displays 3:49:36 (or 229:36 if you used the format [m]:ss).
Top of Page



Fred I found this instruction.
Calculate elapsed time (subtract time)
Elapsed time is the difference between two times. Suppose that you want to
calculate the elapsed time of a practice marathon run that you started at
10:24:00 AM and that ended at 2:13:36 PM, measured to the second.

Do the following:
In cell A1 (or any other cell), type the end time. For example, type
10:24:00 AM.
In cell A2 (or any other cell), type the start time. For example, type
2:13:36 PM.
Tip Make sure that you include a space between the minute value and "AM"
or "PM."

In cell A3, type =A2-A1.
On the Home tab, in the Cells group, click Format, and then click Format
Cells.
In the Format Cells dialog box, click the Number tab.
Under Category, click Custom.
In the Type box, type [h]:mm:ss.
Tip You can also show the results in minutes by setting the format to
[m]:ss.

Click OK.
In cell A3, Excel displays 3:49:36 (or 229:36 if you used the format [m]:ss).
Top of Page

I changed the format I want to display the difference in dd/mm/yy hh/mm/ss
The cell values are





In cell A1 (or any other cell), type the end time. For example, type
10:24:00 AM.
In cell A2 (or any other cell), type the start time. For example, type
2:13:36 PM.
Tip Make sure that you include a space between the minute value and "AM"
or "PM."

In cell A3, type =A2-A1.
On the Home tab, in the Cells group, click Format, and then click Format
Cells.
In the Format Cells dialog box, click the Number tab.
Under Category, click Custom.
In the Type box, type [h]:mm:ss.
 
D

David Biddulph

If you're going beyond 31 days, as Fred said, you'll need to do things
differently. As you've found, you can't format the difference to show mm
and dd fields for months and days.

You can use INT(A2-A1) to give you a number of days (format as number or
general, not as date) and MOD(A2-A1,1) to give you the remaining time in
[h]:mm:ss.

If you want to see a difference in years and months, rather than just days,
you'll have to use DATEDIF (http://www.cpearson.com/excel/datedif.aspx) but
you'll need to think a little about what you consider to be the length of a
month in this context.
--
David Biddulph
Fred, you have helped me but there is still a a problem when
subtracting date and time. It gives me a 1 in the month value when it
is the same month and there should be a 00 there. I have typed my
method and following my method I did find another example but it is
only for hours.

The only thing I did differently was put it in the format of mm/dd/yy
hh:mm:ss however when I have 8/21/2009 11:00:58 PM - 8/1/2009
11:00:50 PM Typed in the formula representing cells =B8-B7 It gives
me this value for elapsed time 01/12/00 16:45:32 there should not be
a 1 in the mm value.

Fred I found this instruction in excel but do not think that it will
solve my problem.
Calculate elapsed time (subtract time)
Elapsed time is the difference between two times. Suppose that you
want to calculate the elapsed time of a practice marathon run that
you started at 10:24:00 AM and that ended at 2:13:36 PM, measured to
the second.

Do the following:
In cell A1 (or any other cell), type the end time. For example, type
10:24:00 AM.
In cell A2 (or any other cell), type the start time. For example, type
2:13:36 PM.
Tip Make sure that you include a space between the minute value and
"AM" or "PM."

In cell A3, type =A2-A1.
On the Home tab, in the Cells group, click Format, and then click
Format Cells.
In the Format Cells dialog box, click the Number tab.
Under Category, click Custom.
In the Type box, type [h]:mm:ss.
Tip You can also show the results in minutes by setting the format
to [m]:ss.

Click OK.
In cell A3, Excel displays 3:49:36 (or 229:36 if you used the format
[m]:ss). Top of Page



Fred I found this instruction.
Calculate elapsed time (subtract time)
Elapsed time is the difference between two times. Suppose that you
want to calculate the elapsed time of a practice marathon run that
you started at 10:24:00 AM and that ended at 2:13:36 PM, measured to
the second.

Do the following:
In cell A1 (or any other cell), type the end time. For example, type
10:24:00 AM.
In cell A2 (or any other cell), type the start time. For example, type
2:13:36 PM.
Tip Make sure that you include a space between the minute value and
"AM" or "PM."

In cell A3, type =A2-A1.
On the Home tab, in the Cells group, click Format, and then click
Format Cells.
In the Format Cells dialog box, click the Number tab.
Under Category, click Custom.
In the Type box, type [h]:mm:ss.
Tip You can also show the results in minutes by setting the format
to [m]:ss.

Click OK.
In cell A3, Excel displays 3:49:36 (or 229:36 if you used the format
[m]:ss). Top of Page

I changed the format I want to display the difference in dd/mm/yy
hh/mm/ss The cell values are





In cell A1 (or any other cell), type the end time. For example, type
10:24:00 AM.
In cell A2 (or any other cell), type the start time. For example, type
2:13:36 PM.
Tip Make sure that you include a space between the minute value and
"AM" or "PM."

In cell A3, type =A2-A1.
On the Home tab, in the Cells group, click Format, and then click
Format Cells.
In the Format Cells dialog box, click the Number tab.
Under Category, click Custom.
In the Type box, type [h]:mm:ss.

Fred Smith said:
Let's get the formatting down first.

Enter =now() in an empty cell.
Right-click on the cell, choose Format Cells...
Based on your post, you should see
mm/dd/yyyy hh:mm
in the Type: box
Add the :ss to the format.

Does this now display the date/time the way you want?
If so, copy this format to your other cells.

Regards,
Fred
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top