VoiceGuide IVR Software Main Page
Jump to content

Using Play_Start COM command

Recommended Posts

I maybe having a similar problem.

 

I'm trying to do the following;

 

strFileToPlay = "C:\1stMy.wav"

PlayWAVFile iLineID, strFileToPlay

strFileToPlay = "C:\2ndMy.wav"

PlayWAVFile iLineID, strFileToPlay



Sub PlayWAVFile(ByVal iLineID, ByVal strFileToPlay)

    set Objvg = CreateObject("VoiceGuide.CommandLink")
         Objvg.Play_Start iLineID, strFileToPlay 
    set Objvg = Nothing

End Sub

 

Actual file names were not used.

 

What happens is the first file starts to play and then the Second file starts to play before the first file is finished playing.

 

What can I do to let the first file play completely before the second file begins to play?

Share this post


Link to post

I've attached a trace of my problem.

 

140554.41  4 cl    Play_Start C:\Program Files\VoiceGuide\system\voice\VmbAccessListenMsgMenu.wav

140554.42  4 tw    ConvertWav2Vox C:\Program Files\VoiceGuide\system\voice\VmbAccessListenMsgMenu.wav

140554.45  0 comlg 1.wav,2.wav,3.wav

140554.48  4 tw    wav->vox convert end 427093,C:\Program Files\VoiceGuide\system\voice\VmbAccessListenMsgMenu.vox,1,0,,

140554.53  4 play  start ok, lPlayId=427171

140554.56  4 cl    Play_Start C:\Program Files\VoiceGuide\system\voice\1.wav, C:\Program Files\VoiceGuide\system\voice\2.wav, C:\Program Files\VoiceGuide\system\voice\3.wav

140554.59  4 tw    ConvertWav2Vox C:\Program Files\VoiceGuide\system\voice\1.wav,C:\Program Files\VoiceGuide\system\voice\2.wav,C:\Program Files\VoiceGuide\system\voice\3.wav

140554.63  4 tw    wav->vox convert end 427265,C:\Program Files\VoiceGuide\system\voice\1.vox,C:\Program Files\VoiceGuide\system\voice\2.vox,C:\Program Files\VoiceGuide\system\voice\3.vox,1,0,,

140554.64  4 play  start ok, lPlayId=427312

140554.67  4 tw    PlayEnd 4 427171

140554.70  4 play  end id=427171, (old ID) current id=427312

140554.72  4 tw    DialogicEvent 129,TDX_PLAY,427171,0,0,,,

140554.75  4 event ScriptEventCode TDX_PLAY, code=129, state=1501

140554.78  4      LsRunWaitTillFinished TDX_PLAY,EV_UNKNOWN_129

140554.81  4      path {TDX_PLAY} not found

140556.23  4 tw    PlayEnd 4 427312

140556.25  4 play  end id=427312, (current ID)

 

Trace is Attached.

 

As you can see as soon as the 2nd file begins to play the 1st one stops. That makes sense.

 

How can I start playing the 2nd file only after the 1st file is finished playing?

 

I'm sure there is something very simple that I'm overlooking.

Share this post


Link to post
What happens is the first file starts to play and then the Second file starts to play before the first file is finished playing.

Issuing a Play_Start COM command will resuklt in VG stopping whatever is being played or recorded on the line and the newly supplied sound file will begin playing.

How can I start playing the 2nd file only after the 1st file is finished playing?

You will need specify the files to be played in one call. Try this:

strFileToPlay = "C:\1stMy.wav,C:\2ndMy.wav"
PlayWAVFile iLineID, strFileToPlay

Sub PlayWAVFile(ByVal iLineID, ByVal strFileToPlay)
   set Objvg = CreateObject("VoiceGuide.CommandLink")
   Objvg.Play_Start iLineID, strFileToPlay 
   set Objvg = Nothing
End Sub

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×