• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Storing script objects
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Storing script objects


  • Subject: Re: Storing script objects
  • From: Richard 23 <email@hidden>
  • Date: Fri, 12 Jan 2001 01:02:36 -0800

>Hi!
>
>I want to build some script objects based on FileMaker data and then
>use Store Script to write a file that can be used by other scripts.
>
>When I change properties of the script they don't get written. For example:
>--------
>script x
> property y : {}
>end script
>
>set x's y to {1, 2, 3}
>store script x in ((path to desktop) as text) & "script file" with replacing
>------

actually they do, but the source isn't updated. It's a good idea to place
a comment in your script saying not to modify, compile and resave or else
data will be lost.

try

load script x
return x's y


BONUS DECEPTION PLOY:

this is effective against less gifted nosy neighbors:

property Prevent: run script "error number -128"

the script will refuse to compile, only silently...
no compile means no save with replace... crafty, eh?


>When I read the file, property y is set to the original {}.
>
>Any ideas?

I have on occasion found it useful to refresh the source but it's
an involved process for which I haven't received patents yet... 8)

>-John


  • Follow-Ups:
    • Re: Storing script objects
      • From: John MacDonald <email@hidden>
  • Prev by Date: Quark missing/modified graphics
  • Next by Date: Re: Script Application handles an event, then quits
  • Previous by thread: Re: Storing script objects
  • Next by thread: Re: Storing script objects
  • Index(es):
    • Date
    • Thread