Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2
Default Duration stored as text

I have several thousand rows of data with time duration stored as
text. For example, "00:30:16" is 30 minutes, 16 seconds. Is there any
way I can convert this to a number, so that I can run calculations on
this time duration?

If I can't, I'll use MATCH and MID to slice up the text into three
separate columns (hours, minutes, seconds), then multiply the first
two appropriately and add them all up as seconds to get the total. I
*really* don't want to do that, though. Please tell me Excel has
something clever I just wasn't aware of yet.

Thanks!

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 2
Default Duration stored as text

On Jul 5, 4:48 pm, test me wrote:
I have several thousand rows of data with time duration stored as
text. For example, "00:30:16" is 30 minutes, 16 seconds. Is there any
way I can convert this to a number, so that I can run calculations on
this time duration?

If I can't, I'll use MATCH and MID to slice up the text into three
separate columns (hours, minutes, seconds), then multiply the first
two appropriately and add them all up as seconds to get the total. I
*really* don't want to do that, though. Please tell me Excel has
something clever I just wasn't aware of yet.

Thanks!


The match/mid wasn't as bad as I thought, since the time duration was
already formatted to have the same number of digits. So I just used

=MID(duration, 1, 2)*3600+MID(duration, 4,2)*60+MID(duration,7,2)

to get the amount of time in seconds.

But if there is a function that does this, I'd like to hear about it.
Thanks!

--Rachel

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
Number Stored as text Error Torero Excel Worksheet Functions 2 December 1st 06 01:28 PM
Numbers stored as text Thorkil Excel Discussion (Misc queries) 1 April 4th 06 05:02 PM
Number stored as text Andrew Clark Excel Discussion (Misc queries) 1 November 8th 05 10:25 PM
Date stored as Text Andibevan Excel Discussion (Misc queries) 3 May 27th 05 03:37 PM
Number stored as text sueanne Excel Discussion (Misc queries) 1 March 2nd 05 10:56 PM


All times are GMT +1. The time now is 11:28 AM.

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"