<div>Hi Jakob,</div><div> </div><div>I'm not 100% sure about this, but my guess is that E-Studio generates code where the inputmask of an object is initialized just before running the object (you can check this in the full-script tab). And, since you run the object explicitly in your own script in the try-again scenario, you also have to initialize the inputmask explicitly yourself because the generated initialization code is not yet called when you execute the run-statement. </div>
<div> </div><div>There are several workarounds for this. I will only explain a scenario that doesn't use a goto-label, because goto's often have negative side effects. My advise would be to put the practice block procedure in another block list that repeats several times (PracMasterList::Exit List = 999). Then, instead of using a goto-label construct, simply call the terminate method in case the ready-criteria are met (PracMasterList.Terminate)</div>
<div> </div><div><font size="1">If PracticeACC.Mean >= .80 Then</font></div><div><font size="1"><div><font size="1"> EndPrac.Text = "Well done"</font></div> PracMasterList.Terminate</font></div><div><font size="1">else</font></div>
<div><font size="1"> EndPrac.Text = "Try again"</font></div><div><font size="1">end if</font></div><div><font size="1"></font> </div><div>You might have to tweak other objects, such as the practice introduction screen, to complete it: If the instruction should not repeat, then you can simply place it before the practice master list. If the practice instructions should repeat with different content, you could make use of a Slide object having different tab's (SlideStates) with specific instructions for the first and repeating runs. The Slide's ActiveState property can be used to select the visible tab. The attached example shows how you can do this. Sounds complicated, but is rather straightfoward without additional inline script. <em>(In words: Define an attribute for the active state in PracMasterList. Use the []-syntax to specify the name of this attribute in the ActiveState property of the Slide. Set the list ordering to sequential and include as many rows as required. Configure the required active state for each row. Exit list should be reset to 1 cycle in this case because the number of 'trials' determine how many times the practice block.)</em></div>
<div><font size="1"></font> </div><div>Cheers,</div><div>Paul</div><div> </div><div><font size="1"></font><br><br> </div><div class="gmail_quote">2012/8/13 Jakob <span dir="ltr"><<a href="mailto:jakob4resilience@gmail.com" target="_blank">jakob4resilience@gmail.com</a>></span><br>
<blockquote style="margin:0px 0px 0px 0.8ex;padding-left:1ex;border-left-color:rgb(204,204,204);border-left-width:1px;border-left-style:solid" class="gmail_quote">Hello everyone!<div><br></div><div>I would really appreciate if someone could help me understand the following:</div>
<div><br></div><div>I have a conditional practice block with a script that displays one text in the following text-object if the accuracy-criterium is met. If the criterium is not met it displays another text in the same text-object and then jumps back to a label (goto). If the criterium is met everything works as intended. But in the case of the criterium not being met the text-object only terminates with input if I manually specify the InputMask for the text-object in the script, not if I merely specifiy the input in the GUI of the text-object (see below)</div>
<div>I'd really like to understand this enigma! ;)</div><div><br></div><div>Thanks in advance!</div><div>Jakob</div><div><br></div><div><font size="1">Here is the relevant part of the experimental procedure and the script in question (CheckACC):</font></div>
<div>--------------------------------------------------------------------------------------------------</div><div><div><font size="1"><b>PracticeBlockProcedure</b></font></div></div><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<div><div><font size="1"><b>Setup</b> (Script that sets a Summation Variable)</font></div></div></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b>PracticeInstruction</b> (TextDisplay Object)</font></div>
</blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b>Label2</b> (Label)</font></div></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<div><font size="1"><b>Reset</b> (Script that resets the Summation Variable)</font></div></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b>Practice List</b> (List Object)</font></div>
</blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b>PracticeListProcedure</b></font></div>
</blockquote></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<div><font size="1"><b>PracticeDisplay</b> (ImageDisplay Object)</font></div></blockquote></blockquote></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b>PracticeFeedback</b> (FeedbackObject)</font></div></blockquote></blockquote></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b>AddObservation</b> (Script that adds the ACC of the PracticeDisplay to the Summation Variable so it can be compared to the criterium later on)</font></div>
</blockquote></blockquote></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b><i>CheckACC</i></b> (Script that checks if the ACC criterium has been met and branches accordingly; <b>the line in question is in talics - see below</b>)</font></div>
</blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><font size="1"><b>EndPrac</b> (TextDisplay Object that displays a text depending on the CheckACC script)</font></div></blockquote>
<div>-------------------------------------------------------------------------------------------------- <br></div><div><b><i><u><br></u></i></b></div><div><b><i><u>CheckACC-Script:</u></i></b><br></div><div><font size="1">If PracticeACC.Mean >= .80 Then</font></div>
<div><font size="1"><span style="white-space:pre-wrap"> </span>EndPrac.Text = "Well done."</font></div><div><font size="1">Else</font></div><div><font size="1"><span style="white-space:pre-wrap"> </span>EndPrac.Text = "Try again."</font></div>
<div><span style="white-space:pre-wrap"><font size="1"> </font></span><i style="font-size:x-small">EndPrac.InputMasks.Add Keyboard.CreateInputMask("{SPACE}", "", CLng(Pause.Duration), CLng("1"), ebEndResponseActionTerminate, CLogical("Yes"), "", "", "ResponseMode:All ProcessBackspace:Yes")</i></div>
<div><font size="1"><span style="white-space:pre-wrap"> </span>EndPrac.Run</font></div><div><font size="1"><span style="white-space:pre-wrap"> </span>Goto Label2</font></div><div><font size="1">End If</font></div><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<div> </div></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div> </div></blockquote></blockquote></blockquote></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<div> </div></blockquote></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div> </div></blockquote></blockquote>
<blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div> </div></blockquote></blockquote><blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor">
<blockquote style="margin:0px 0px 0px 40px;padding:0px;border:currentColor"><div><div> </div></div></blockquote></blockquote><span class="HOEnZb"><font color="#888888"><div><div> </div></div><div><br></div><div><br></div>
<p></p>
-- <br>
You received this message because you are subscribed to the Google Groups "E-Prime" group.<br>
To post to this group, send email to <a href="mailto:e-prime@googlegroups.com" target="_blank">e-prime@googlegroups.com</a>.<br>
To unsubscribe from this group, send email to <a href="mailto:e-prime%2Bunsubscribe@googlegroups.com" target="_blank">e-prime+unsubscribe@googlegroups.com</a>.<br>
To view this discussion on the web visit <a href="https://groups.google.com/d/msg/e-prime/-/atKZiK1ES_MJ" target="_blank">https://groups.google.com/d/msg/e-prime/-/atKZiK1ES_MJ</a>.<br>
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank">https://groups.google.com/groups/opt_out</a>.<br>
<br>
<br>
</font></span></blockquote></div><br>
<p></p>
-- <br />
You received this message because you are subscribed to the Google Groups "E-Prime" group.<br />
To post to this group, send email to e-prime@googlegroups.com.<br />
To unsubscribe from this group, send email to e-prime+unsubscribe@googlegroups.com.<br />
For more options, visit <a href="https://groups.google.com/groups/opt_out">https://groups.google.com/groups/opt_out</a>.<br />
<br />
<br />