Yeah, cmd is not the most friendly shell I have come across ;\)

Allen: "C:\something or the other.txt" needs to be quoted as you have done, but runnas requires the whole command that it is to run to be quoted, as in (too lazy to change the internal single quotes to char() function calls):

 Code:
$cmd='runnas.exe /user:joe "KIX32.EXE kixScript.kix $passedFile='C:\something or the other.txt'"'


but cmd or/and runnas does not like single quote parameter quoting