Hi folks
I am making a mp3 id3tag editor, and a regex is not matching. Could anyone help me please? my code:
arquivo = "[coletanea] album [CD #] [faixa] [artista] musica.mp3"
r = New Regex("^\[(?<1>[^\]]+?)\]\s*(?<2>[\w\s]+)\s*\[CD\s*(?<3>\d+)\]\s*\[(?<4>\d+)\]\s*\[(?<5>[^\]]+)\]\s*(?<6>.+)", RegexOptions.Compiled)
m = r.Match(Mid(arquivo, 1, Len(arquivo) - 4))
If m.Success Then
mAuthor = Trim(m.Groups(5).ToString)
mWM_AlbumTitle = Trim(m.Groups(2).ToString)
mWM_TrackNumber = Trim(m.Groups(4).ToString)
mTitle = Trim(m.Groups(6).ToString)
mWM_PartOfSet = Trim(m.Groups(3).ToString)
mMW_AlbumArtist = Trim(m.Groups(1).ToString)
End If
thx