This site will work and look better in a browser that supports
web standards, but it should be accessible for any browser or Internet device.
If you're seeing this message, you may have to scroll to the bottom of the page to
see the navigation links.
Opening Password Protected FileMaker Pro Databases
Help!
I recently spotted a message in the forum on Fileville --a site devoted to the database program FileMaker Pro-- in which an individual was wondering how to use AppleScript to open a database that requires a password. After I wrote a brief note explaining some of the ins and outs, I thought everyone over here might be interested.
First, a sample that I've been using with a client's files. Of course, the clients name and password are changed to protect the innocent:
tell application "FileMaker Pro" activate open {file "Macintosh HD:Business:Projects:PROPOSAL"} ¬ with password "login" end tell
Claris actually _almost_ documents this, but leaves out the critical point that curly brackets ( "{" and "}" ) must surround the list of files. Ah, yes, that does mean you can extend this to a list of files. For example, if you added a second file called "CUSTOMERS" in the same folder as the PROPOSAL file, you would change you script:
tell application "FileMaker Pro"
activate open {file "Macintosh HD:Business:Projects:PROPOSAL", ¬ file "Macintosh HD:Business:Projects:CUSTOMERS"} ¬ with password "login" end tell
Reach out and touch someone's stuff
The final common spin that I use is that of logging into hosted databases running on another machine. On the last set of examples, I'm going from memory, so if you run into problems, feel free to email me and I'll check my notes.
Let's assume that the database "PROPOSAL" you want is in a folder called "files" on a machine called "MyServer". To actually open the file, you'll need to have the server's harddrive mounted on your desktop; probably using the chooser. Your script would like this:
tell application "FileMaker Pro" activate open {file "MyServer:files:PROPOSAL"} ¬ with password "login" end tell
What's more likely is that a co-worker is hosting several files and you want to sign in as a guest from your computer. For this your script changes a little:
tell application "FileMaker Pro" activate open {file "PROPOSAL" of machine "MyServer"} ¬ with password "login" end tell
If you want to access the machine via TCP/IP --and presumably IPX-- simply use the Server's IP address for it's name.
Possibilities of dogs chasing the car
That last example is the one time in which I've run into situations where the script will not work in some cases. The now anonymous client has a multiple zone network that has the side-effect of blocking attempts to have FileMaker Pro log-ins between zones. Strangely, it works fine within a zone.
The other common problem that you might run into is that older versions of Apple's ObjectSupportLib sometimes cause problems with AppleScript for certain programs. The easiest solution is usually to make sure you have the latest version installed (1.2 as I type) which is included with MacOS 7.6 and is probably available seperately on the websites of Apple and Claris.