Results 1 to 6 of 6

Thread: [RESOLVED] Searching for 2 bytes lost - id3tag v1.1

Threaded View

  1. #1

    Thread Starter
    Hyperactive Member RS_Arm's Avatar
    Join Date
    Mar 2007
    Location
    Planet Earth
    Posts
    282

    Resolved [RESOLVED] Searching for 2 bytes lost - id3tag v1.1

    Hello guys.

    So, I'm trying to read the id3 tag from a mp3 file but I just don't know why I just can't read the track number info. Could you give me a help?

    Code:
    Dim Gens(125) As String
    
    
    Dim free As Integer
    Private Type TagInfo
        Tag As String * 3
        NomeFaixa As String * 30
        Artista As String * 30
        Album As String * 30
        Ano As String * 4
        Comentario As String * 30
        NFaixa As String * 2
        Genero As String * 1
        
    
    End Type
    
    
    
    Private Function Songinfo(filepath As String)
    Dim CurrentTag As TagInfo
    
    'Get the song info
    Open filepath For Binary As #1
        
        
    With CurrentTag
        Get #1, FileLen(filepath) - 127, .Tag
        Get #1, , .NomeFaixa
        Get #1, , .Artista
        Get #1, , .Album
        Get #1, , .Ano
        Get #1, , .Comentario
        Get #1, , .Genero
        Get #1, , .NFaixa
        
        txtTag.Text = .Tag
        txtSong.Text = RTrim(.NomeFaixa)
        txtArtist.Text = RTrim(.Artista)
        txtAlbum.Text = RTrim(.Album)
        txtAno.Text = RTrim(.Ano)
        txtComentario.Text = RTrim(.Comentario)
        txtGenero.Text = Gens(Asc(RTrim(.Genero)))
        txtNFaixa.Text = RTrim(.NFaixa)
    End With
    
    Close #1
    End Function
    
    Private Sub Command1_Click()
    Songinfo ("D:\New Folder (2)\file.mp3")
    End Sub
    
    
    Private Sub Form_Load()
    Gens(0) = "Blues"
    Gens(1) = "Classic Rock"
    '...
    End Sub
    This link might help you to help me.
    Thank you and
    Merry Christmas to everybody!
    Last edited by RS_Arm; Dec 24th, 2007 at 01:20 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width