Reset embedded data while using Retake Link and Retake as New Response Link | XM Community
Solved

Reset embedded data while using Retake Link and Retake as New Response Link

  • 26 September 2019
  • 1 reply
  • 68 views

Userlevel 7
Badge +6
Hello -

I am using the Retake Links as a way to edit/copy forms as part of a renewal process. For the most part, the functions of the links work great. For example, the Retake Link shows the form at the time the form was first taken and pre-loads the earlier selections/entries, while the Retake as a New Response Link looks at the form in its most current form and pre-loads earlier selections (great for renewals with small changes).

However, my form uses A LOT of conditional branching logic to set embedded data. This embedded data is either used to format an output (manually setting HTML so that the form is "dynamic") or is used for math operations. During testing I noticed that embedded data is also saved, even if the conditional logic is no longer true, which can cause some very big problems downstream for the math operations and formatting. (see images below for and example).

I realize this may be tedious, as I have A LOT of embedded data variables, but is there a way to reset/clear embedded? I know I can replace the values of embedded data by setting it to a value at the top of the survey flow, but in order to work properly, I need the embedded data to be blank.

Test Example:
!
!

Note - The second answer was done using a Retake as a New Response Link.
icon

Best answer by Akdashboard 26 September 2019, 16:06

View original

1 reply

Userlevel 7
Badge +6
SOLUTION FOUND

It may be a bit tedious with a lot of embedded data values, but you CAN empty embedded data with the following JavaScript. I set it in the first question seen when the retake links are used.

Qualtrics.SurveyEngine.addOnload(function()
{

Qualtrics.SurveyEngine.setEmbeddedData('Value', '');

});

By using 2 single ticks, the embedded data "Value" is rest/emptied (I guess technically set to nothing).

Leave a Reply