View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.programming
teepee[_4_] teepee[_4_] is offline
external usenet poster
 
Posts: 27
Default Media Player versus Windows Media Player


"michelxld" wrote
in message ...

Hello

try this macro

WindowsMediaPlayer1.currentMedia.duration

or

Dim ValMin As Double, ValSec As Double, S As Double
S = WindowsMediaPlayer1.currentMedia.duration
ValMin = Application.WorksheetFunction.RoundDown((S / 60), 0)
ValSec = Application.WorksheetFunction.RoundDown(S, 0) - (ValMin * 60)
MsgBox Format(ValMin, "00") & ":" & Format(ValSec, "00")


Thank you. I will try it and let you know how it went

tp