When the ParseInt runs, it just pulls the integer piece of the number, and drops any info to the right of the decimal point. To work around that, I multiplied my embedded field by 100 in the survey flow, then pulled in that integer, and after pulling it into JS, dividing by 100 and working with that result.
From the TobG urlencode link above, I took the code and got it working. It took me a while because it seems like most of the pages that demonstrate the Qualtrics setEmbeddedData command show (what looks like) a dot between the name of the variable and the value to which it is being set. I wouldn't work until I change it to a comma. Below, in my last line, that is ('NoSpace' comma encodedInputString); From there, the "NoSpace" variable/embedded data can easily be piped to the email trigger (or email action). Qualtrics.SurveyEngine.addOnReady(function() { var inputString="${e://Field/WithSpace}"; var encodedInputString=escape(inputString); encodedInputString=encodedInputString.replace("+", "%2B"); encodedInputString=encodedInputString.replace("/", "%2F"); Qualtrics.SurveyEngine.setEmbeddedData('NoSpace',encodedInputString); });
Already have an account? Login
Enter your username or e-mail address. We'll send you an e-mail with instructions to reset your password.
Sorry, we're still checking this file's contents to make sure it's safe to download. Please try again in a few minutes.
Sorry, our virus scanner detected that this file isn't safe to download.