I'm trying to replace this unrecognized � text below here to a another text. What I did is decode it to UTF-8 and try to replace the unknown text below.
" you�"
varlistlabela = spss.GetVariableLabel(var)
varlistlabela=varlistlabela.decode("cp1252").replace(r'[\u0020-\ud7ff]',"").encode("cp1252")
str.replacedoesn't understand character ranges like[\u0020-\ud7ff]. Were you thinking ofre.sub?