Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Global variables

1 view
Skip to first unread message

eph

unread,
Nov 28, 2006, 3:50:58 PM11/28/06
to
Hello,
I am having a problem getting my MIAW to recognise a global variable.
What I am basically trying to do is send a name of a file from the
stage to a MIAW which then imports the file and plays it.
Heres the code I am using from the stage:

global gVideoPlaying

on playVideoButton
gVideoNum = gMyLine -- set the video to be played to the currently
highlighted track
if videos = [] then exit -- abort if no tracks in playlist
if gVideos=0 then -- if nothing is currently playing...
window().new("Video Player")
window("Video Player").filename = "Viewing window.dir"
gVideoPlaying = member("VideoList").text.line[gVideoNum] -- set
gVideoPlaying to video name from VideoList
window("Video Player").moveToFront()
window("Video Player").open()
end
------------------------------------------------------------------------------------

The code for the MIAW is:
global gVideoPlaying

on openWindow()
importFileInto member 5, gVideoPlaying -- the file is set to member
5, if the name of the file is hard coded here the video will play
sprite(1).membernum = 5 -- sprite 1 is replaced with the video and
then played
end
------------------------------------------------------------------------------------

Any help would be great. Am sure its just a silly mistake somewhere.
Thanks.

0 new messages