I am trying to record audio files for an experiment that I am creating. Here is the code I am using:
Code: Select all
global gSubjectID
global recordcount
on mouseUp
set the recordFormat to "wave" -- or "wave" or "ulaw"
set the recordCompression to "raw "
put 1 into recordcount
set the itemDelimiter to "/"
get the effective fileName of this stack
set the defaultFolder to item 1 to -2 of it
if not (the hilite of me) then
if recordcount is 1 then
put gSubjectID & space & "Question 1.wav" into fld "recordFileName"
put fld "recordFileName" into sndName
# make sure there's a name
if sndName is empty then
exit mouseUp
end if
set the hilite of me to true
record sound file sndName
add 1 to recordcount
end if
end if
end mouseUp
Code: Select all
on mouseUp
stop recording
set the hilite of btn "record" to false
end mouseUp
I am using Livecode 7.01
Quicktime is installed
Thanks!