View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.misc
David127 David127 is offline
external usenet poster
 
Posts: 11
Default Convert Min & Hrs to Min in Decimal

Thanks for the quick reply Peo but I get "3" for both 3:00 & 3:00:00.


"Peo Sjoblom" wrote:

What's the difference between A2 and A3? Because if it is formatting then
the underlying value is the same. If the values are text

=IF(LEN(A2)-LEN(SUBSTITUTE(A2,":",""))1,1440*A2,24*A2)

if not then there is no difference between A2 and A3


--


Regards,


Peo Sjoblom


"David127" wrote in message
...
I'm pasting text into excell & need a decimal count of minutes. The
problem
comes in that some text is refering to hours and sometimes to minutes & I
can't come up with a formula to handle both.
Ex: Paste the following
A1 - 2:00
A2 - 3:00
A3 - 3:00:00
A4 - 3:40:00

Should convert to
A1 = 2
A2 = 3
A3 = 180
A4 = 220

Thanks!