>I am writing an application to catalog MP3's. I would like to read the properties contained in the MP3 file(s), such as the Name, Artist, Album, Genre, Length, Bitrate etc., so that I can import this info. into my table, without having to manually input all the MP3's information.
>
>How can I gain access to this information contained in the MP3 file? I am using VFP 6.0 and VFP 7.0.
Check on wotsit site (
http://www.wotsit.org/). To get theme/artist info you can build a reader from the following code (not robust at all):
m.lnFile = FOPEN(GETFILE())
FSEEK(m.lnFile,-128,2)
m.lcTag = FREAD(m.lnFile,128)
? "Title:",STRTRAN(SUBSTR(m.lcTag,4,30),CHR(0))
? "Artist:",STRTRAN(SUBSTR(m.lcTag,34,30),CHR(0))
? "Album:",STRTRAN(SUBSTR(m.lcTag,64,30),CHR(0))
? "Year:",VAL(SUBSTR(m.lcTag,94,4))
FCLOSE(m.lnFile)
----------------------------------
António Tavares Lopes