Re: Persistence of properties in AppleScripts within FileMaker Pro scripts
Re: Persistence of properties in AppleScripts within FileMaker Pro scripts
- Subject: Re: Persistence of properties in AppleScripts within FileMaker Pro scripts
- From: Bill Briggs <email@hidden>
- Date: Tue, 4 Mar 2003 12:59:14 -0400
At 5:05 PM +0100 04/03/03, julifos wrote:
> I'm trying to set up some tools of convenience for myself in a
FileMaker Pro database I made that tracks my students' marks, lab
attendance, etc. I've attached several FileMaker Pro scripts to
buttons and part of the FileMaker Pro script is often an embedded
AppleScript. The current script I want to use in this way requires me
to store a property, but there seems to be no persistence of
AppleScript properties between runs. I can't think of a workaround in
AppleScript. I could, of course, make a field in the database and
store it there, but I would rather not - it's already got 250 fields.
I guess one more wouldn't hurt, but...
Does anyone know how to make properties stick in AppleScripts run
within FileMaker Pro's scripting architecture?
- web
I'm not a FM expert
Nor am I.
but seems that FM executes a text script, anything such as a "do
script" command or:
run script "set x to x +1"
So, if no compilation, not properties persistence...
I've no idea what's happening inside of FileMaker Pro. I have the
script in the "Perform AppleScript" command's argument. It appears to
work fine, but for the property issue. I have some other ones that'll
be used in the same database and involve other applications, and I'm
not optimistic that they will all work flawlessly. But it's
interesting to see what can be done to jazz up a database with a few
conveniently located scripts. Twenty such scripts are destined for
this particular database.
Sweet ways are your idea about create a new field (if you can store
such property in a text field)
A number field, actually, but yes, that's what I'm doing now.
write it to a preferences file,
Could do that, but I want to keep the number of files to a minimum,
and want it to be something that others here can use, so I'm not
going to go for the prefs file.
or directly execute the script from an external compiled script, or
store the results into one:
I think it would have to be a script application if you want to
trigger it from an apple event. This was my second choice, and I may
still have to do it that way. I'll have a bunch of scripts to drag
around with the database, but it will certainly work.
Perform AppleScript ["run script alias 'path:to:script'"]
Equivalent outcome to sending an aevt to launch a script application.
Perform AppleScript ["store script x in file y replacing yes"]
(which is the same as write the property to a file)
I'll go for one of the less convoluted solutions. A year from now I
might forget what I did.
- web
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.