Skip to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Auto-open database with or without password - Command line?

Featured Replies

Hi,

Having recently purchased a Filemaker Pro 11 license, I would like to setup a copy on our office server that opens a single database without any user interaction. I can easily manage launchctl on Mac to make sure the program is always running or started on boot, but I'm unsure as to how I should manage users and passwords.

I want each user to still have to put in the username and password when connecting to the remote server, but I want the database to open on the server without any interaction needed. If I create a password-less account for loading the database, I wouldn't want anyone else to be able to login using that account.

What are my options? Can I load a database from the command line with the username and password included there?

Thanks for your help.

Andy.

  • Author

After searching for quite a while, I can't for the life of me find a simple way to open a database from the command line. This must be so simple to do, but I can't find the solution anywhere. It's important the the database re-open after a power cut, nightly reboot or anything like that and pluggin in a monitor (or using VNC) and manually opening the file is just not an option.

Can anyone point me in the right direction?

Thanks

It doesn't sound like you are using FileMaker Server. FMS takes care of all that for you.

To open a FM file for peer-to-peer hosting you can use a VBScript and embed the account & pw in there. Check out the FM help file for "activeX". Since this would only work if a user is logged into the server you'll always have a security risk.

  • Author

Thanks for the reply.

As we are only about three people in the office, Filemaker Pro Server would be overkill. The server is running OS X, so I guess Applescript would be the way to go. I was hoping that a basic shell script would cover it, but I guess that would just be too easy! ;)

starter.fp7.zip

You need to create a Filemaker file whose sole purpose is to open the main file.

This starter.fp7 has the account and password for the main file installed and set as default in the file options. Additionally a start script that simply opens the main file.

This starter script can be launched via /usr/bin/open.

Since this starter script is used to open the main database, you have to secure it somehow.

Attached is a minimal starter file where you need to fill in the account, external file reference and openWithAccount attributes.

  • Author

Thanks Karsten.

The starter file seems simple enough. Could you expand on the part where I have to place the starter script in /usr/bin/open?

I am able to start the Filemaker app with Launchctl on Mac, but can't pass the file as a parameter (or don't know how)

I am also able to open a database directly by placing the .fp7 file in the login items. OS X knows which application to use to open the file, But when it opens, Filemaker just bounces up and down in the dock and doesn't do anything else until I click on the icon, at which point it continues to load the database correctly... not much use on a server.

So basically, how do I open the starter.fp7 file on a Mac when rebooting without needing any user interaction?

Hopefully someone has come across this before and knows the answer.

Thanks again!

Put it in Apple menu->System Preferences...->Accounts->Login Items

You'll have to experiment.

FileMaker is a picky WRT how it's getting launched. Remember: insisting on having a open dialog on launch; only opening files when it's frontmost app etc.

If putting the starter into the users startupitems works for you, you're fine.

Otherwise the options are:

An AppleScript like this

tell application "FileMaker Pro Advanced"

activate

open ("Volume:folder:starter.fp7" as alias)

end tell

Or writing a launchdaemon. See Apple docs for that.

Things that work on one machine might not on another. Try and error.

As we are only about three people in the office, Filemaker Pro Server would be overkill.

Depends what your data is worth to you. Especially if you are concerned with power outages etc. as you mentioned. I don't think FMS for a 2 or 3 person office is overkill at all.

Thanks for the reply.

As we are only about three people in the office, Filemaker Pro Server would be overkill.

Emphatically not, particularly if the system is mission critical to the business. You are trying to make the database behave in a way it's really not designed to operate. FileMaker Server provides all the needed functionality for safe and robust hosting to multiple users.

Steven

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.