Have you tried putting a "stop" statement after the line item.StreamFormat = validstr(curShow.streamFormat.GetText()) ?
Then, when the debugger runs, type: ?curShow.streamFormat.GetText()
Also I notice that in the next line that you have commented out:
'if item.StreamFormat = " " then 'set default streamFormat to 'hls if doesn't exist in xml
when you get around to uncommenting that line you might want to change the " " to "" (i.e. no space between the quotes) if you're testing for an empty string rather than testing for a string that contains exactly one space character.