How to set timeout longer - Applescript in Filemaker controlling Fetch

I am trying to upload a database to a web server via Fetch 4.0.3.

Filemaker 6 is initiating the applescript from a Filemaker script.

Everything works well, until an error appears saying Filemaker needs attention. The error says Fetch Apple Event has timed out. Fetch is, in fact, still uploading, but my Filemaker script continues to the next step, sending an email telling the host to swap out the database. But it’s not fully uploaded yet! So, I need some way to supress the error, or set the timeout somewhere longer.

Any help?? :slight_smile:


with timeout of 300 seconds
Tell application "FileMaker Pro" to do script yourScript
end timeout

Wow! Applescript IS just like english!! :slight_smile:

Thanks, I’ll try it.

Nope, it didn’t work! Fetch begins the upload, and in exactly 2 minutes Filemaker posts this error:

Fetch 4.0.3 got an error: AppleEvent timed out. (Error -1712).

Here is my code (I made the delay long to see if there is a change. Result: no change!):

tell application “Fetch 4.0.3”
activate
with timeout of 2300 seconds
open remote directory “ftp://myserver.com
put into transfer window “filename and path” format Automatic without uniquename
end timeout
quit
end tell

More ideas???
Thanks!

I just solved my problem - it is a bug in filemaker that has been there for years! The FM Script work around looks like this for me:

I created the script as an application file on the hard drive.

Send Apple Event → Open Application → UploadDatabase.app
Pause [20 minutes]
Send email to swap the database

The file takes 17 minutes to upload now, so I gave it a little more for the future.

Works fine, but now I have to manage the extra file!

Here’s a post that helped me discover this:
http://fmforums.com/forum/showtopic.php?tid/79628/

Hope this helps the next guy who stumbles on this problem!