Re: FileMaker "do script"
Re: FileMaker "do script"
- Subject: Re: FileMaker "do script"
- From: David Crowe <email@hidden>
- Date: Sun, 22 Jun 2008 08:41:11 -0600
Bruce;
The major problem is that it seems like it is impossible to associate
"do script" with anything but the frontmost window. If you have three
different FileMaker databases running, how do you bring the right one
to the front so that the "do script" command doesn't fail.
And why the heck can't you qualify "do script" with a
database/window/table/layout like other FileMaker applescript
comments? (not that I expect anyone to be able to provide an answer,
it just seems like a bad decision on FileMaker's part).
- David
> It seems to me that FileMaker (8.0v2) will only execute a script in
the frontmost window. If you say <<tell database "MyDatabase" to do
script "MyScript">> this will fail unless "MyDatabase" happens to be
frontmost.
FileMaker's documentation implies this, because their example is:
tell application "FileMaker Pro"
do script FileMaker script 1 -- the first script
do script last FileMaker script -- the last script
do script FileMaker script ¬
"Print Sales Report" -- a script by its name
do script FileMaker script after ¬
FileMaker script 1 -- the second script
do script FileMaker script before ¬
FileMaker script 3
-- the second script
do script (every FileMaker script ¬
whose name begins with "aName") -- all scripts meeting a test
end tell
If my intuition is correct, this is really annoying because it makes
the script very intrusive, unable to truly run in the background.
Perhaps I can just make the database come to the front of all the
FileMaker tables without making FileMaker active, but that's still
intrusive if I'm using FileMaker for something else.
- David
It's not quite that simple.
FileMaker scripts CAN run in the background.
Some script steps will cause the window to come to the front, particularly
record navigation and layout navigation.
tell application "FileMaker Pro Advanced"
set D to a reference to document "DYMO Addresses"
set s to a reference to FileMaker script "Sort by Address" of D
do script s
-- Filemaker remains in background
-- called window remains in background
end tell
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden