Thread: time to integer
View Single Post
  #10   Report Post  
Posted to microsoft.public.excel.programming
NickHK[_3_] NickHK[_3_] is offline
external usenet poster
 
Posts: 415
Default time to integer

Ivan,
Alt+F11, right-click the workbook tree, add a module.
Paste in

Public Function MakeScore(argInput As Variant) As Long
MakeScore = Replace(argInput.Text, ":", "") * 1000
End Function

Then in the worksheet, type :
=MakeScore("A1")
or the cell of interest

NickHK

"Ivan" .88...
"NickHK" wrote in news:OVgwLQV6GHA.1188
@TK2MSFTNGP05.phx.gbl:

Ivan,
Something like:
MsgBox Replace(Range("A2").Text, ":", "") * 1000

NickHK


hey Nick, I get your idea but I know nothing about
showing MsgBox from Excel, or macro's .. :(
I have like - field A1 where my 00:00:54,121 time is
and I need to get nubmer 54121 written in A2
from this A1 field.. (so A2 depends on A1)
if you could just say what I need to type in A2 field,
a formula or expression ;)


Ivan (Bllich)