showController for audio question???
Ban Nguyen
bann at sunncomm.com
Wed Jul 13 15:06:22 EDT 2005
Hello,
I use this code for video and it works perfect
set the showController of the templatePlayer to true
play videoclip "My Clip"
I use the similar code for audio and it does not work. It plays the
song but does not show the controller
set the showController of the templatePlayer to true
play audioclip "My Clip"
-------------------------
My problem is: I have a list of 9 songs and I want to show them in a
list and let user click on one song at a time and play it
I use the scrolling list field to display those songs. Here is the code
of the scrolling list field:
on mouseup
global gClickVar
select the clickLine
put word 2 of the clickLine into gClickVar
-- get the song name
put line gClickVar of field "audioList" into gClickVar
play audioClip gClickVar looping
end mouseup
----------------------
I create a play button. Here is the code for the play button (it works
fine):
on mouseUp
global gClickVar
play audioClip gClickVar looping
end mouseUp
-------------------------
I also create the stop, prev and next button. They works fine
-----------------------
My problem is I don't know how to create the volume slider to control
the volume
-----------------------
I use this code for the pause button:
on mouseUp
global gClickVar
play pause audioClip gClickVar
end mouseUp
It stops the song and plays the beginning of the song when I release the
mouse. I want to pause it and click again to continue play (not
beginning)
---------------------
so that why I am trying to use this code so I don't have to worry about
volume and stuff...:
set the showController of the templatePlayer to true
play audioclip "My Clip"
but it does not work
---------
Does the player object play the imported song (import as a control) or
only play songs on the hard drive that you insert in the source
(C:\audio\songs....)
Please help me. Anyone has any idea? Thank you
More information about the use-livecode
mailing list