add items from a list to an array in E-prime
Ben Robinson
brobinso at mprc.umaryland.edu
Wed Mar 7 20:20:49 UTC 2007
something along these lines should work:
Dim i as Integer
Dim array(List1.Size-1) as String
For i=1 to List1.Size
array(i-1) = List1.GetAttrib i, "ColumnName"
Next i
ben robinson
>>> "Tobias Johansson" <batne at hotmail.com> 3/2/2007 6:20 AM >>>
Hi!
I have a question about arrays that I cannot really figure out on my own.
I have a variable with a number of items in a list. I want these items added to an array in the beginning of the experiment because I want to search through the array through out the course of the experiment, e.g. "If the subjects response in the array then do X, otherwise do Y". I have no problems with the code for searching the array. But I do have problems with adding all of the items in the list to an array in an economical fashion.
I have set up a trial procedure with an inline script so the experiment goes through all the items in the list, one by one, and adding them to the array. But this generates a lot of saved trials and the datafile gets messy (of course I can filter the data file, but still....). Is there any way to, in one big fat step, just add a whole list of items to an array, without using any trialprocedure, but just referring to the list?
Best regards
Tobias Johansson
Lund University, Sweden
Express yourself instantly with MSN Messenger! MSN Messenger Download today it's FREE!
More information about the Eprime
mailing list