Project: VB6AudioConverter
Version: 3.0.0
Report Date: 08/06/2023 12:05:58
By: Yaron Goali (WISERBIT DOT COM) for Microncode.com
User Control: cAudioConverter
VB6AudioConverter is an OCX component for software developers.
This component can convert MP3, WMA, WAV, OGG and APE audio files, from one format to another. This component can also deal with the ID3 tags of the audio files, can get general information about an audio file (bitrate, length, time...), supports many events, easy to the use, and much more…
Home Page:
https://www.microncode.com
This CHM file contains the documentation and the description about all the functions/events/properties this component is using.
For more information about how to operate this component, please look inside the samples.
The samples of this component contains a clearly and easy to understand source code with a description for each line.
If you need more help, feel free to contact us via: https://www.microncode.com/support/
Properties
ConvertLengthSec [Let] - Public
Set the length to convert in seconds.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
Long |
ConvertStartFromSec [Let] - Public
Set the second to start convert from.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
Long |
ConvertTo [Let] - Public
Set the format of the destination audio file:
MP3 - Convert to MP3 audio file.
WMA - Convert to WMA audio file.
WAV - Convert to WAV audio file.
OGG - Convert to OGG audio file.
APE - Convert to APE audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
eConvertTo |
Destination [Let] - Public
Set the destination of the file to convert.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Info_Bitrate [Get] - Public (Return Datatype: Long)
Info_BitsPerSample [Get] - Public (Return Datatype: Long)
Info_Channels [Get] - Public (Return Datatype: Integer)
Info_Duration [Get] - Public (Return Datatype: Long)
Info_Samplerate [Get] - Public (Return Datatype: Long)
SourceFile [Let] - Public
Set the source file to convert.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_Album [Let] - Public
Set the Albume tag for the destination audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_Album [Get] - Public (Return Datatype: String)
Get the Albume tag of the source audio file.
Tag_Artist [Let] - Public
Set the Artist tag for the destination audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_Artist [Get] - Public (Return Datatype: String)
Get the Artist tag of the source audio file.
Tag_Comment [Get] - Public (Return Datatype: String)
Get the Comment tag of the source audio file.
Tag_Comment [Let] - Public
Set the Comment tag for the destination audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_Genre [Let] - Public
Set the Genre tag for the destination audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_Genre [Get] - Public (Return Datatype: String)
Get the Genre tag of the source audio file.
Tag_SongYear [Let] - Public
Set the SongYear tag for the destination audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_SongYear [Get] - Public (Return Datatype: String)
Get the SongYear tag of the source audio file.
Tag_Title [Let] - Public
Set the Title tag for the destination audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_Title [Get] - Public (Return Datatype: String)
Get the Title tag of the source audio file.
Tag_TrackNumber [Let] - Public
Set the TrackNumber tag for the destination audio file.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
String |
Tag_TrackNumber [Get] - Public (Return Datatype: String)
Get the TrackNumber tag of the source audio file.
WriteWAVHeader [Let] - Public
Write the wav headers of ACM and PCM wav files. Default value is true.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
RHS |
Boolean |
Subroutines
About - Public
Description: Display About message box with the license details.
Convert - Public
Description: Start the conversion.
Return: Nothing, if an error apear, the Error event will be fire.
DisplayRegistration - Public
Description: Display registration window.
SetACM - Public
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
sTag |
String |
|
ByVal |
sFormat |
String |
SetAPE - Public
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lCompressionLevel |
Long |
SetMP3 - Public
YARON
Set the new MP3 properties. This was not finished.
Optional | ByVal/ByRef | Variable | Datatype |
|
|
MP3Properties |
MP3_Properties |
SetMP3Vals - Public
Set the new MP3 properties for C++.
Description: Set the MP3 target without using the MP3_Properties type (for C++, etc..).
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
ABRBitrate |
Long |
|
ByVal |
Bitrate |
Long |
|
ByVal |
CopyrightBit |
Boolean |
|
ByVal |
ErrorProtection |
Boolean |
|
ByVal |
Mode |
MPEGMode |
|
ByVal |
OriginalBit |
Boolean |
|
ByVal |
SampleRate |
Long |
|
ByVal |
Quality |
Long |
|
ByVal |
StrictISO |
Boolean |
|
ByVal |
VBR |
VBRMode |
|
ByVal |
VBRForceMinBitrate |
Boolean |
|
ByVal |
VBRMinBitrate |
Long |
|
ByVal |
VBRMaxBitrate |
Long |
|
ByVal |
VBRQuality |
Long |
|
ByVal |
WriteVBRTag |
Boolean |
SetOGG - Public
Optional | ByVal/ByRef | Variable | Datatype |
|
|
OGGProperties |
OGG_Properties |
SetOGGVals - Public
Description: Set the OGG target without using the OGG_Properties type (for C++, etc..).
Quality_Mode = 1
Bitrate_Mode = 2
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lMode |
Long |
|
ByVal |
lBitrateNominal |
Long |
|
ByVal |
lQuality |
Long |
SetWAV - Public
Optional | ByVal/ByRef | Variable | Datatype |
|
|
WAVProperties |
WAV_Properties |
SetWAVVals - Public
Description: Set the WAV target without using the WAV_Properties type (for C++, etc..).
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lSampleRate |
Long |
|
ByVal |
nChannels |
Integer |
|
ByVal |
nBitsPerSample |
Integer |
Functions
Cancel - Public (Return Datatype: Cancel())
CloseFile - Public (Return Datatype: CloseFile())
Added : 18/10/2006
Calose the stram so the source file can be deleted
at the end of the proccess.
ConvertX - Public (Return Datatype: Long)
Description: Start the conversion, the next code line will operate when the conversion is done.
Return: Nothing, if an error apear, the Error event will be fire.
DeInit - Public (Return Datatype: Long)
Description: DeInit the component, must be call before closing the program.
Return: 0 if success, otherwise a number describe the error.
GetAudioInfo - Public (Return Datatype: Long)
Description: Get information about the strFile audio file .
Return: Nothing, if an error apears, the Error event will be raise.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
strFile |
String |
GetFormatsByTag - Public (Return Datatype: Long)
Public Function GetFormatsByTagX(ByVal sTagsName As String) As Long
'Description: Get the formats of the sTagsName.
'Return: Formats collection of the ACM tag name.
On Error GoTo ErrGetFormatsByTagX
Dim i As Long
Dim x As Long
Dim y As Long
Dim cntr As Long
Dim lNumOfFormatUnderTag As Long
For i = 0 To codecs.count - 1
For x = 0 To UBound(codecs.drivers(i).Tags)
If Left(StrConv(codecs.drivers(i).Tags(x).detail.szFormatTag, vbUnicode), Len(sTagsName)) = sTagsName Then
For y = 0 To codecs.drivers(i).Tags(x).formatcount - 1
lNumOfFormatUnderTag = codecs.drivers(i).Tags(x).formatcount
RaiseEvent TagFormats(StrConv(codecs.drivers(i).Tags(x).formats(y).detail.szFormat, vbUnicode))
Next y
Exit Function
End If
Next x
Next i
GetFormatsByTagX = lNumOfFormatUnderTag
Exit Function
ErrGetFormatsByTagX:
GetFormatsByTagX = -1
RaiseEvent Error(Err.Number, Err.Description)
End Function
Description: Get the formats of the sTagsName.
Return: Formats collection of the ACM tag name.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
sTagsName |
String |
GetID3Tags - Public (Return Datatype: Long)
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
strFile |
String |
GetTagInfo - Public (Return Datatype: String)
Description: Get information about sTagName.
Return: String that describe the information about tag name.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
sTagName |
String |
GetTags - Public (Return Datatype: Long)
Description: Get all the ACM tags that installed on the local machine.
Return: Collection of ACM tags.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lFormatTag |
Long |
|
ByVal |
lSamplesPerSec |
Long |
|
ByVal |
lChannels |
Long |
|
ByVal |
lBitsPerSample |
Long |
|
ByVal |
eTagMode |
eTagsMode |
Init - Public (Return Datatype: Long)
Description: Init the component, must be call before using any functionality of the component.
Return: 0 if success, otherwise a number describe the error.
Optional | ByVal/ByRef | Variable | Datatype |
Optional |
ByVal |
sKey |
String |
OpenFile - Public (Return Datatype: Long)
Change : 18/10/2006
Set the OpenFile function to public.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
strFile |
String |
SecondsAsTimeString - Public (Return Datatype: String)
Get time length in seconds and return somthing like 02:22:08
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lSeconds |
Long |
SetWMA - Public (Return Datatype: Boolean)
Optional | ByVal/ByRef | Variable | Datatype |
|
|
WMAProperties |
WMA_Properties |
SetWMAVals - Public (Return Datatype: Boolean)
Description: Set the WMAV target without using the WMAV_Properties type (for C++, etc..).
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lCodec |
Long |
|
ByVal |
lFormat |
Long |
TagCodecs - Public
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
sTagName |
String |
TagFormats - Public
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
sTagFormat |
String |
WMACodecFormats - Public (Return Datatype: Collection)
Description: Get a list of WMA formats of the lCodecIndex.
Return: Collection type of list of WMA format.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lCodecIndex |
Long |
WMACodecFormatXVal - Public (Return Datatype: String)
Description: Get the WMA format name of the lCodecIndex by the lFormatIndex.
Return: A string with the codec name.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lCodecIndex |
Long |
|
ByVal |
lFormatIndex |
Long |
WMACodecs - Public (Return Datatype: Collection)
Description: Get a list of WMA codecs.
Return: Collection type of WMA codecs.
WMACodecsFormatsX - Public (Return Datatype: Long)
Description: Get a counter of the number of the formats by the lCodecIndex value.
Return: A long with a counter of the number of the codecs by the lCodecIndex.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lCodecIndex |
Long |
WMACodecsX - Public (Return Datatype: Long)
Description: Get a counter of the number of the WMA codecs that installed on the local machine.
Return: A long with a counter of the number of the WMA codecs.
WMACodecXVal - Public (Return Datatype: String)
Description: Get the WMA codec name by the lIndex.
Return: A string with the codec name.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lIndex |
Long |
Event Declares
Aborted - Public
Raise when the converting proccess has aborted.
Done - Public
Raise when the converting proccess has done.
Error - Public
Error handling: ErrNum - error number, ErrDescription - error description.
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lErrNum |
Long |
|
ByVal |
sErrDescription |
String |
Progress - Public
The progress of the conversion (percent between 0 to 100).
Optional | ByVal/ByRef | Variable | Datatype |
|
ByVal |
lPercent |
Long |