Problem was:
-Evillyrics replaces some characters with Underscores
-till now i have found two: "'" and ","
So i have added a replace-part in the code, very simple to add new characters.
thats why i think, minilyrics is not for free:
http://www.crintsoft.com/mlbuy.htm
Code: Select all
Sub EvilTagger
'This scripts imports the Lyrics from Evillyrics
'set the Evillyrics Cache options to "Cache organization ---> by first letter"
'
'Script will check if the lyrics.txt file of the selected songs exists
'and import it then to the lyrics tag
'Filename must be "Artist - Title.txt"
'Possible erros are strange characters in the Artist or Title Tag, e.g. "C'est la vie" or "ä/22*~"
'Here are the ini-Lines
'[Eviltagger]
'FileName=Eviltagger.vbs
'ProcName=Eviltagger
'Order=10
'DisplayName=EvilTagger
'Description=Import Lyrics from Evillyrics
'Language=VBScript
'ScriptType=0
DIM path, filename
DIM list, itm
DIM headline,lyrics, line
DIM msg, errorcounter, filecounter, msgtext
'######################################################
'Set the Errorcounter to his starting point
errorcounter = 0
'Set the Path to the Evillyrics Lyrics
'Evillyrics Options must be set to "Cache organization ---> by first letter" --> see below
path = "C:\Programme\Evillyrics\Lyrics\"
'######################################################
' Get list of selected tracks from MediaMonkey
Set list = SDB.CurrentSongList
filecounter = list.count
' Process all selected tracks
For i=0 To list.count-1
Set itm = list.Item(i)
'##################################################
'set the headline of the Lyrics
headline = itm.artistname & " - " & itm.title & CHR(10) &"___________________________________" & CHR(10)
'##################################################
' Create Filename
filename = itm.artistname & " - " & itm.title & ".txt"
'####################################################
' Evillyrics replaces some characters with underscores. Put them in here:
filename = replace(filename,"'","_")
filename = replace(filename,",","_")
'####################################################
' by adding the first letter of the artist to the path ("Cache organization ---> by first letter")
'and then the Evillyrics scheme
filename = path & "\" & left(itm.artistname,1) &"\" & filename
Set filesys = CreateObject("Scripting.FileSystemObject")
If filesys.FileExists(filename) = true Then
Set file = filesys.OpenTextFile(filename, 1, false)
'add headline to the beginning of the Lyrics
lyrics = headline
Do while not file.AtEndOfStream
line = file.ReadLine
lyrics = lyrics & chr(10) & line
Loop
'write Lyrics to the Lyrics tag
itm.lyrics = lyrics
Else
errorcounter = errorcounter +1
End if
Next
' Write all back to DB and update tags
list.UpdateAll
'#####################################################
'set the final message
msgtxt = filecounter - errorcounter & " of " & filecounter& " lyrics imported "
msgtxt = msgtxt & CHR(10)& CHR(10) & "check missing lyrics manually, e.g. filename versus artist, title tag"
'#####################################################
'final user information
Msg = SDB.MessageBox(msgtxt , mtInformation, Array(mbOk))
End sub

