Hola amigos,
el siguiente es un posible código para extraer información de un archivo audio WAV sólo con las funciones de gambas, y, en particular, con la utilización de un array de tipo Byte[ ].

Public Sub Main()

Dim percorsoFile As String
Dim fl As File
Dim bb As Byte[]
Dim solo_dati, frequenza As Integer


percorsoFile = "/dirección/del/archivo.wav"

fl = Open percorsoFile For Read

bb = New Byte[44]

bb.Read(fl, 0, 44)

fl.Close

If bb.ToString(0, 4) <> "RIFF" Then Error.Raise("El archivo subido no es de tipo 'RIFF' !")

If bb.ToString(8, 4) <> "WAVE" Then Error.Raise("El archivo subido no es de tipo 'WAVE' !")

If bb.ToString(12, 4) <> "fmt " Then Error.Raise("El archivo subido no es de tipo 'fmt ' !")

Print "== características del archivo: "; File.Name(percorsoFile); " ==\n"

Print "Tamaño total del archivo: "; Stat(percorsoFile).Size; " byte"

solo_dati = Stat(percorsoFile).Size - 44
Print "Tamaño de sólo datos audio: "; solo_dati; " byte"

If bb[20] = 1 Then
Print "Formato audio: PCM"
Else
Print "Formato audio: "; bb[20]
Endif

Print "Canales de salida de audio: "; bb[22]

frequenza = Val("&" & Hex(bb[27]) & Hex(bb[26]) & Hex(bb[25]) & Hex(bb[24]))
Print "Frecuencia de muestreo: Hz "; frequenza

Print "Byte rate: "; Val("&" & Hex(bb[31]) & Hex(bb[30]) & Hex(bb[29]) & Hex(bb[28])); " Bps"

Print "Resolución de muestreo: "; bb[34]; " bit"

Print "Duración de los datos audio: "; Date(0, 0, 0, 0, 0, 0, Fix((solo_dati * 8) / (frequenza * bb[34] * bb[22])) * 1000)

End