Subject id from .txt file


Author
Message
peppo
peppo
Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)
Group: Forum Members
Posts: 2, Visits: 1

Hi everyone,


I'm trying to string together different experiments (authorware and inquisit), with inquisit coming last. I want inquisit to use an id number that was specified earlier in the experiment.


I've tried to use authorware to start inquisit with an id number like this:


"C:\.......\script.exe 22"


but this way every participant in inquisit gets the same number. I can't get the subject id variable between the "" in authorware..


Perhaps it is possible to start inquisit with a subject id read from a text file? That way I could have authorware create a .txt with the subject id, and have inquisit read that file..


Any help would be greatly appreciated! :)


Cheers,


Peppo.



Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 12K, Visits: 98K

Authorware should be able to append a variable (i.e. the id collected earlier) to a batch call. I'd try something like


JumpOut("C:\Program Files\Millisecond Software\Inquisit 3\Inquisit.exe", "C:\Experiments\MyExperiment.exp"; VariableNameToPass)


where 'VariableNameToPass' is the variable that holds the participant ID collected earlier.


If this doesn't work, I'd create a simple Windows text file containing the following line


"C:\Program Files\Millisecond Software\Inquisit 3\Inquisit.exe" "C:\Experiments\MyExperiment.exp" %1


and save it as 'startexp.bat' in the same direcory as the Authorware file. Then the first command would simplify to


JumpOut(FileLocation^"\\startexp.bat"; VariableNameToPass)


Some useful links:



Once you've worked out a solution, please post it here. Others will appreciate it.


~Dave


peppo
peppo
Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)Partner Member (592 reputation)
Group: Forum Members
Posts: 2, Visits: 1

Hi Dave,


thanks for the reply! :D I used the .bat to get it to work! :)


I almost figured it out myself, except that I used this:


JumpOut("\\startexp.bat"; VariableNameToPass)


Which didn't work, now I've just used the following (difference is in the two backslashes, which Is stupid anyway :p):


JumpOut("startexp.bat"; VariableNameToPass)


(the .bat is in the same directory..)


Thanks a lot!


Cheers, Peppo



so, a recap on the solution for future readers:



  • create a .bat file (using notepad) which contains the program and script, and %1, like so:

    • "C:\Program Files\Millisecond Software\Inquisit 3\Inquisit.exe" "C:\Experiments\MyExperiment.exp" %1



  • Save this as startexp.bat and use this to start your inquisit experiment in authorware (or other software for that matter..)

  • Save the subject id in a variable (in this example: VariableNameToPass)

  • line to start in authorware:

    • JumpOut(FileLocation^"\\startexp.bat"; VariableNameToPass)





Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 12K, Visits: 98K

Great! And thanks for posting a detailed outline of your solution -- I'm sure other users will find this very helpful.


Best wishes from a fellow Inquisit user,


~Dave


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search