Has anyone been successful with writing an AppleScript that handles closing FileMaker when communication with the host has been interrupted? What I'm looking to do is run this AppleScript at the OS side of things to test if FileMaker is still connected to the server (probably means testing if a dialog is freezing FM, if a database file is accessible, or even if a dummy test file can be opened.) If yes then nothing to do. If there is an error then the communication with host dialog has likely popped up saying it's been interrupted and I would then like to dismiss that dialog, close FileMaker, have AppleScript pause and open an opener file that opens files on the server again for normal services to be resumed.
I've tried various combinations of things but not been successful as yet.
I know that one way of tackling this is to look at why the disconnect happens in the first place, but as things stand that's not the current way forward and I'm looking to address these disconnects as above for now. Longer term, these functions running on the local network may address the bigger issue, but that's a little way off for right now.
Many thanks for any tips to try.