The full path to file created by the last sound capture done for this element.
<block> <expt> <likert> <openended> <sliderTrial> <survey> <surveyPage> <trial>
event.name.lastSoundCapturePath
Read Only
string
This property is useful in playing recorded responses back to participants during the same script session.
If the element is a block, this returns the lastsoundCapturepath given on the most recent trial that was run within the block. If the element is a trial, this returns the lastsoundCapturepath given the last time the trial was run.
The following displays the value of lastSoundCapturePath in a text stimulus:
<text myText>
/ items= ("lastSoundCapturePath = <% trial.myTrial.lastSoundCapturePath %>")
</text>
The following displays the value of lastSoundCapturePath in an instruction page:
<page myPage>
lastSoundCapturePath = <% trial.myTrial.lastSoundCapturePath %>
</page>
The following code shows a) how to store the full path for a soundcapture into 'item.currentProposedSolution' and b) how to use the stored soundCapture to present it back to the participant during runtime.
<item currentProposedSolution>
</item>
<sound proposedSolution>
/ items = item.currentProposedSolution
</sound>
<trial solution>
/ onTrialBegin = {
item.currentProposedSolution.clearItems();
}
/ stimulusFrames = [1 = instruct]
/ validResponse = (" ")
/ soundCapture = true
/ onTrialEnd = {
item.currentProposedSolution.appendItem(this.lastSoundCapturePath);
}
/ branch = {
return trial.presentSolution;
}
</trial>
<trial presentSolution>
/ stimulusFrames = [1 = clearScreen, proposedSolution] //presents the recently taken soundcapture
/ validResponse = (" ")
</trial>