Need help with script to set mp3 tag from partial filename

The error is coming from the next line, which looks like it was from JScript. VBScript has functions like SubStr(...), not object methods like x.Substring(...)