Saving stack changes under Player

André.Bisseret Andre.Bisseret at
Tue Dec 19 14:58:01 EST 2006

Le 19 déc. 06 à 17:08, Mark Swindell a écrit :

> Is it possible to save changes made to stacks when run under the  
> Player?  If so, what is the mechanism?  At this point I just want  
> field text changes to be retained between sessions.  But what about  
> adding cards and such as that?
> Thanks
> Mark

Yes it is possible, with a handler in the script of the stack

on saveStack
save this stack (or save stack "suchStack"
end saveStack

and a button (where you want) the script of which  could be :
on mouseUp
end mouseUp

If you want you could have a handler to allow the user to choose in  
case he is trying to close ;
something like :

on closeStackRequest
   answer "Save this stack ?" with "Yes" or "No" or "Cancel"
     if it is "Yes" then saveStack
if it is "No" then
     close this stack
     exit closeStackRequest
  end if
  if it is "cancel" then exit closeStackRequest
  pass closeStackRequest
end closeStackRequest

Best regards from Grenoble

> _______________________________________________
> use-revolution mailing list
> use-revolution at
> Please visit this url to subscribe, unsubscribe and manage your  
> subscription preferences:

More information about the Use-livecode mailing list