New User - Could use some help with Time Formatting

Bart196

New Member
Joined
Dec 11, 2017
Messages
8
I want this time (09:31:09.880) to show as (09:31:09). I need to exclude the milliseconds.

The cell is currently formatted as hh:mm:ss.000

If I try to format the cell using the time function (hh:mm:ss), Excel will round to the nearest second, this is a problem.

I've also tried converting the time into a text, but I'm not sure how to remove the milliseconds from the text format.



****** id="cke_pastebin" style="position: absolute; top: 0px; width: 1px; height: 1px; overflow: hidden; left: -1000px;">

09:31:09.880

<tbody>
</tbody>
</body>
 

Excel Facts

Who is Mr Spreadsheet?
Author John Walkenbach was Mr Spreadsheet until his retirement in June 2019.
If I try to format the cell using the time function (hh:mm:ss), Excel will round to the nearest second, this is a problem

Keep in mind that cell formatting DOES NOT effect the actual value held in the cell.
So even if the cell formatting shows the time 'rounded', you can rest assured the 'real' original value is in fact still there.

Cell formatting only changes how a value 'appears' in the cell, not the actual underlying value.



A1 has the hard coded time, formatted as only hh:mm:ss
B1 has a formula returning the value of A1, formatted as hh:mm:ss.000


Book1
AB
109:31:1009:31:09.880
Sheet1
Cell Formulas
RangeFormula
B1=A1
 
Last edited:
Upvote 0
Keep in mind that cell formatting DOES NOT effect the actual value held in the cell.
So even if the cell formatting shows the time 'rounded', you can rest assured the 'real' original value is in fact still there.

Cell formatting only changes how a value 'appears' in the cell, not the actual underlying value.



A1 has the hard coded time, formatted as only hh:mm:ss
B1 has a formula returning the value of A1, formatted as hh:mm:ss.000

AB
109:31:1009:31:09.880

<colgroup><col style="width: 25pxpx"><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Sheet1

Worksheet Formulas
CellFormula
B1=A1

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>


Thanks for teaching me something new today!
 
Upvote 0

Forum statistics

Threads
1,216,115
Messages
6,128,919
Members
449,478
Latest member
Davenil

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top