There is a function used in scripting custom CBC questions using Free Format questions: CBCDesignLevelValue(ExerciseName_CBCQuestionName, ConceptPosition#, LevelTextPosition#)
Assuming the following:
CBC exercise is called "Pizza"
You want to check the second task, i.e. "Random2"
Brand is attribute 9
If you wanted to pull from the design the Brand level number for the first concept, you would use
[% CBCDesignLevelValue(Pizza_Random2, 1, 9) %]
You can also reference the concept chosen anywhere in a survey by referencing the name of the question, i.e. [%Pizza_Random2%].
By putting the two together, you can retroactively figure out what brand was chosen in the 2nd question with the following:
[% CBCDesignLevelValue(Pizza_Random2, PizzaRandom2, 9) %]
For the second statement of PizzaRandom2, if I chose the third concept it would evaluate to a 3, and thus the script would look like this: [% CBCDesignLevelValue(Pizza_Random2, 3, 9) %] which would then return the 9th attribute level text from the 3rd concept of the second Random task of the Pizza exercise.