September 26, 200322 yr Hi, I've been using an applescript application for some time which just asks FMPro to run a script every five minutes. It's really just: ------------------------ repeat tell document "markzlog" of application "FileMaker Pro" activate do script "importlog" end tell delay 300 end repeat ------------------- But now I have to add an extra database to it and I find the problem is that I need to call the two database windows to the front in turn to make the script run. how can I call each database window to the front from my script? thanks, jeff
September 26, 200322 yr You can bring a window to front using the following when dbName is your database name. This assumes the database is already open. tell application "FileMaker Pro" activate go to window "dbName" end tell
September 26, 200322 yr Since you are already using the document reference in the tell statement: tell document "markzlog" of application "FileMaker Pro" It should run the script in the correct file without having to bring the window to the front.
September 29, 200322 yr Author Hi, thanks, I'll give that a try. ...........yes, works a treat. It will even hook the database out of the dock where I left it by mistake. thanks! jeff
September 29, 200322 yr Author Hi, thanks, I'll give that a try. This was the two-database one which wouldn't work, but would if I manually swopped the windows around during its wait time: repeat tell document "markzlog" of application "FileMaker Pro" activate do script "importlog" end tell delay 30 tell document "isdnfood" of application "FileMaker Pro" activate bring to front do script "import_all" end tell delay 300 end repeat thanks, jeff
Create an account or sign in to comment