If there are table occurrences on the graph of your interface on the local computer, FileMaker will typically try to open the referenced files when it opens - before the OnOpen script runs, as you have noticed.
To avoid the "Open Missing File" dialog, I'm afraid you'll need to test for the availability of the hosted file by using a file on the end-user's computer other than your main interface file. This "test for host" file should have a file reference to the hosted file(s), but no table occurrences pointing to tables in the hosted files.
To confirm that a hosted file is available, you can use the Open File [ YourHostedFile ] script step in an OnFileOpen script, and then test for Get(LastError). If the hosted file is available, Get(LastError) will be zero, and the script should open the file on the local computer. If the hosted file is not available, Get(LastError) will return a non-zero value (100 for "File is missing" or 802 for "Unable to open file"), and the script can display a custom dialog or text on a layout informing the user that the hosted file is unavailable.
An opener file, even if you it's not your first choice for other reasons, can perform this task - and you can configure the system so that users don't deal directly with more than one file.
I hope this helps.
Senior Consultant, NightWing Enterprises
FileMaker Certified Developer (7, 8, 9, 10 and 11)
Speaker, FileMaker Developer Conference, USA, 2007, 2009 and 2010
Thanks. I hoped that I could avoid the extra opner file, but if it can't be done, it can't be done.....
Maybe something for Filemaker to consider. How to run a script before anything else.