Detecting mouse clicks

ELine elinebp at hotmail.com
Tue Nov 15 15:15:41 UTC 2011


I really appreciate your help, but I can't get it to function.

The general setup is this: The subject is to complete 5 tasks
(collected in a trial list): relaxing, listening to speech, reading,
counting backwards, and listening to music. For each trial a 5 sec
intro is made and then 3 minutes of performing the task.
I've defined the attributes 'Visual' and 'Sound' (to control the text
and sound) which are both objects in my slide named Task. For the
reading I don't want any sound, but I want a piece of text to be
displayed. When the subject has read the text (and 3 minutes have not
passed) they should be able to 'turn the page' bu pressing the mouse.
When 3 minutes have passed the task should end and the intro to the
next presented. It all works, except for the reading.

In my Task slide I have defined the input masks to be the mouse with
{ANY} in the allowed response and (none) in End Action, under advanced
I put Max Count to 99. Most of the tasks have a separate state in the
slide, and the reading takes in the variable 'ReadText' to be
displayed. The InLine script (placed before the slide Task) now looks
like this:

If c.GetAttrib("Visual") = "read" Then
 c.SetAttrib "ReadText", "Page 1"

 If  Task.InputMasks(1).Responses.Count >0 Then
   c.SetAttrib "ReadText", "Page 2"
 End If

End If


When comming to the reading task the text "Page 1" is displayed, but
no matter how hard I slam on the mouse, I cannot get the text to
change to "Page 2".

I have also tried with the following script (simply to try something):

If c.GetAttrib("Visual") = "read" Then
c.SetAttrib "ReadText", "Page 1"
Task.InputMasks.Reset

	If Mouse.GetState() = ebStateOpen Then
		TaskEchoClients.RemoveAll
		Task.InputMasks.Add Mouse.CreateInputMask("{ANY}", "",
CLng(Task.Duration), CLng("99"), ebEndResponseActionNone,
CLogical("Yes"), "", "", "")

		If  Task.InputMasks(1).Responses.Count >0 Then
  			c.SetAttrib "ReadText", "Page 2"
		End If
	End If

End If



But with no luck... I cannot seem to understand that my pressing the
mouse is not registered by E-Prime. How can it not !?!

-- 
You received this message because you are subscribed to the Google Groups "E-Prime" group.
To post to this group, send email to e-prime at googlegroups.com.
To unsubscribe from this group, send email to e-prime+unsubscribe at googlegroups.com.
For more options, visit this group at http://groups.google.com/group/e-prime?hl=en.



More information about the Eprime mailing list