<div>I am trying to execute the following do..until statements in the context of a dot probe task. The loop below basically checks whether the participant clicked on a designated area(a cnvs rectangle copied to the destination marked as "FeedbackDest"). Assuming the participant does not click on this region, no action is taken. One can get out of the loop only by hitting the designated spot. There is a music that precedes this statement, and basically, when one hits a prompt, a music follows, and the participant is directed to this region to click (basically to proceed with a fresh trial). Once the participant clicks on this region, the music stops. </div><div><br></div><div>While I get this to work for a participant who answers correctly (i.e. clicks on the correct/designated area), when one clicks on a different area of the screen - the music continues to play (as it should), but right after that, if I were to click on the designated spot - nothing happens (ideally, it should proceed to the next set of images). </div><div><br></div><div><br></div><div><div>If confirmation_flag = 1 then</div><div><span class="Apple-tab-span" style="white-space:pre"> </span></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>If Not theSoundOut Is Nothing Then</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>theSoundOut.Play</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>'Manipulate the SlideSoundOut properties and methods</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>'Debug.Print theSoundOut.Filename</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>nResponseCount2 = 0</div></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Do </div><div><span class="Apple-tab-span" style="white-space:pre"> </span>If mouseMask2.Responses.Count > nResponseCount2 then</div><div><span class="Apple-tab-span" style="white-space:pre"> </span> </div><div><span class="Apple-tab-span" style="white-space:pre"> </span>nResponseCount2 = nResponseCount2 + 1</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Set theMouseResponseData2 = CMouseResponseData(mouseMask2.Responses(nResponseCount2))<span class="Apple-tab-span" style="white-space:pre"> </span> <span class="Apple-tab-span" style="white-space:pre"> </span> <span class="Apple-tab-span" style="white-space:pre"> </span> <span class="Apple-tab-span" style="white-space:pre"> </span></div><div><span class="Apple-tab-span" style="white-space:pre"> </span> strHit2 = theFeedbackState.HitTest(theMouseResponseData2.CursorX,theMouseResponseData2.CursorY)<span class="Apple-tab-span" style="white-space:pre"> </span></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>ptCurrentfb.x = theMouseResponseData2.CursorX</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>ptCurrentfb.y = theMouseResponseData2.CursorY<span class="Apple-tab-span" style="white-space:pre"> </span></div><div> <span class="Apple-tab-span" style="white-space:pre"> </span>if PointInRect(ptCurrentfb, FeedbackDest) then </div><div><span class="Apple-tab-span" style="white-space:pre"> </span>strHit2 = "Correct"</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>'exit Do</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>else</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>strHit2 = "checkagain"</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>end if</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>End if</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Debug.print "strHit2" & strHit2</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Loop until strHit2 = "Correct"</div><div><div> If Not theSoundOut Is Nothing Then</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>theSoundOut.Stop</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>Set theSoundOut = Nothing</div><div> <span class="Apple-tab-span" style="white-space:pre"> </span>End if<span class="Apple-tab-span" style="white-space:pre"> </span></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>End if</div><div><br></div><div>End if</div></div><div><br></div><div>Please let me know where I am going wrong.</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 e-prime@googlegroups.com.<br />
To unsubscribe from this group, send email to e-prime+unsubscribe@googlegroups.com.<br />
To view this discussion on the web visit <a href="https://groups.google.com/d/msg/e-prime/-/mLLYtc8IFtwJ">https://groups.google.com/d/msg/e-prime/-/mLLYtc8IFtwJ</a>.<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 />