finding path of a the current filemaker database

hello all,

I’ve spent loooots of hours trying to do this, find a way to do it, but nothing…

here’s the problem:

I have a database open in fileMaker.
I will run an applescript from my database, which should do the following:

  1. find the path to the current database
  2. open a file sittuated in a folder next to that database.

well, only point 1 is the difficult here, since once I get the path to my database I will be able to open anything next to it.

I tried to find the path to a script in script editor, but the best it would do was get the path to the app…

Is there a way to get the path of a specific filename and not providing the initial path?

TIA

enzo

In FileMaker 6 (maybe earlier versions as well), you can create a calculation field whose value is ‘Status (CurrentFilePath)’. You can then retrieve the value via AppleScript and use it to construct the path.

– Rob

nice one Rob!, works great!

what if I wanted to find the path of a pdf opened in acrobat? (this one is out of curiosity)

I don’t know if it’s possible or how to do it.

– Rob

Here’s the code for the path to the front PDF open in Acrobat:

Jon


[This script was automatically tagged for color coded syntax by Script to Markup Code]

it doesn’t work for me…
It displays an error: ‘can’t make some data into the expected type’
(and I had a pdf document open)