Trying to get data from ascii to a string

Unless you tell us which function is the "soap function", what the input to the function is and what output you are expecting then we don't know where to look.