VideoEdit Gold ActiveX Control

AddAudio Method

Description

Add the audio to timeline. This Method support file format include: MOV, MP4, 3GP, DIVX, AVI, WMV, MPEG1,Dat, MPEG2, VOB, FLV, F4V, AVCHD, MP3, WMA. If you add video file, it will extract the audio track into timeline.

 

Syntax

Public Function AddAudio ( _
   ByVal strFile as string, _
   ByVal iAudioStart as double, _
   ByVal iAudioStop as double
) As Boolean

 

Parameters

strFile
    the file path of audio file

iAudioStart
    the start time of video time you want extract

iAudioStop
    the end time of video time you want extract
 

Return Value

Return true - successful
Return false - Failed
 

Example

[Visual Basic Syntax]
VideoEdit1.InitControl
VideoEdit1.AddAudio "c:\test3.mp3" , 0,10     'Add test3.mp3 into timeline and extract audio of the test3.mp3 from 0 second to 10 second
VideoEdit1.AddAudio "c:\test4.mp3" , 4,8      'Add test4.mp3 into timeline and extract audio of the test4.mp3 from 4 second to 8 second
VideoEdit1.Preview