Saving stack changes under Player

André.Bisseret Andre.Bisseret at inria.fr
Tue Dec 19 13:58:01 CST 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
saveStack
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
André

> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your  
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
>




More information about the use-livecode mailing list