in reply to passing vars to a sub

How is it "not working"? You probably shouldn't quote your arguments.