Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Convert function in Excel

Status
Not open for further replies.
Mar 2, 2006
37
US
Hello,

I need to convert this 0:12:57 to seconds
I'm not sure on how to do it in Excel.

I tried doing this =convert(A2,"sec") but I get an error.


Thanks,

Rita
 
=A2*86400
read this: faq68-5827 to find out why

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
Depending on what you are going to be doing with this data, this might work for you:

Just format the cell to show the number of seconds:
Go to Format > Cells > Number > Custom then in the box at the right, type in [attn][/attn].

This doesn't actually change the number stored in Excel, it only changes what is displayed. As Geoff suggested, read FAQ68-5827 for more info on how Excel deals with dates and times.

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ181-2886 before posting.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top