You could use fileIO xtra which comes along with Director. fileIO xtra
allows you to read and write text files from local hard drive. I usually
create text files in users windows/temp directory and write a property list
like [#playCheck:1]. here is a script for you to go through...
global gPlayCheck, fileObj, gVariableList
on startMovie
-- this list goes into text file
gVariableList = [#playCheck:0]
end
on readTextFile
fileObj = new(xtra "fileIO")
openFile(fileObj, getOSDirectory() & "\temp\Variables.txt",0)
status = status(fileObj)
if status <> 0 then
-- File doesn't exist
gPlayCheck = 0
return
end if
-- file exist, read the text file
gVariableList = value(readFile(fileObj))
gPlayCheck = gVariableList.playCheck
end
on writeTextFile
openFile(fileObj, getOSDirectory() & "\temp\Variables.txt",0)
-- delete the file for fresh entry
delete(fileObj)
-- create a new file
createFile(fileObj, getOSDirectory() & "\temp\Variables.txt")
-- open the file
openFile(fileObj, getOSDirectory() & "\temp\Variables.txt",0)
-- update the list
gVariableList.playCheck = gPlayCheck
-- write the list to text file
writeString(fileObj, string(gVariableList))
-- close the text file
closeFile(fileObj)
fileObj = 0
end
regards
Ramesh C T
-----Original Message-----
From: Tab Julius <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED] <[EMAIL PROTECTED]>
Cc: [EMAIL PROTECTED] <[EMAIL PROTECTED]>
Date: Tuesday, October 03, 2000 12:42 PM
Subject: Re: <lingo-l> making a variable change the second time a cd-rom is
run
>
>Well, you can't write to a CD-ROM. You could look into the Lingo commands
>"SetPref" and "GetPref"...
>
>At 11:17 PM 10/2/00 -0400, Conrad Ayala wrote:
>>I am creating a CD-ROM with a director .exe in it. There is a variable in
>>the cd, let's say "playCheck". The first time it is run,plays check is
set
>>to equal "0". The second time the cd is run, how can I make the variable
>>"playCheck" set to 1? Any help would be appreciated. Thank you.
>>
>>
>>Conrad Ayala
>>Interface Architect
>>The Spin Group, Inc.
>>http://www.spingroup.com/
>>Phone 1-414-672-8888 Fax 1-414-672-8183
>>
>>
>>[To remove yourself from this list, or to change to digest mode, go to
>>http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
>>email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
>>Lingo-L is for learning and helping with programming Lingo. Thanks!]
>
>
>[To remove yourself from this list, or to change to digest mode, go to
>http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
>email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
>Lingo-L is for learning and helping with programming Lingo. Thanks!]
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo. Thanks!]