Error Capture doesn't suppress dialog
Error Capture doesn't suppress dialog
(OP)
We're using Filemaker 8, and we're working with a solution that draws company data for drop-down lists that our users will use to complete a form on their Macs. The data are drawn from 1 of 2 possible FMP files (the file on their Mac, or a file hosted on a FMP8 Server).
Users of this database might be in a location where a network connection is not possible; if that's the case a startup script that tests setting bogus data to a global field on the FMP Server-hosted database is invoked and, if it fails, the users are sent to a layout where the drop-lists are driven by tables in the local file.
However, if a network connection exists (and the test script succeeds), the users are sent to a layout with drop-lists driven by tables on the FMP Server-hosted database. Here's where I run into my problem.
Here's my script:
Set Error Capture [On]
Set Field [MyHostedFile::g_status; "1"]
If [Get(LastError) > 0]
Set Field [ MyLocalFile::g_network_status; "Not Connected']
Go To Layout [Local Drop List]
Set Error Capture [Off]
Halt Script
Else
Set Field [ MyLocalFile::g_network_status; "Connected']
Perform Script ["Import Table1"]
Perform Script ["Import Table2"]
Perform Script ["Import Table3"]
Go To Layout [Local Drop List]
Set Error Capture [Off]
Halt Script
End If
Although I have error capture turned on, I still get a FileMaker dialog box that says "MyHostedFile" could not be opened (Not Found). Our users won't know what to do with this message. I thought that turning Error Capture on would suppress the dialog, but it isn't. Any clue why, or what I might be able to do?
Users of this database might be in a location where a network connection is not possible; if that's the case a startup script that tests setting bogus data to a global field on the FMP Server-hosted database is invoked and, if it fails, the users are sent to a layout where the drop-lists are driven by tables in the local file.
However, if a network connection exists (and the test script succeeds), the users are sent to a layout with drop-lists driven by tables on the FMP Server-hosted database. Here's where I run into my problem.
Here's my script:
CODE
Set Error Capture [On]
Set Field [MyHostedFile::g_status; "1"]
If [Get(LastError) > 0]
Set Field [ MyLocalFile::g_network_status; "Not Connected']
Go To Layout [Local Drop List]
Set Error Capture [Off]
Halt Script
Else
Set Field [ MyLocalFile::g_network_status; "Connected']
Perform Script ["Import Table1"]
Perform Script ["Import Table2"]
Perform Script ["Import Table3"]
Go To Layout [Local Drop List]
Set Error Capture [Off]
Halt Script
End If
Although I have error capture turned on, I still get a FileMaker dialog box that says "MyHostedFile" could not be opened (Not Found). Our users won't know what to do with this message. I thought that turning Error Capture on would suppress the dialog, but it isn't. Any clue why, or what I might be able to do?
RE: Error Capture doesn't suppress dialog
===================
On suppresses FileMaker Pro alert messages and some dialog boxes. If the error result is 100 or 803, then certain standard file dialog boxes are suppressed, such as the Open dialog box.
Off re-enables the alert messages. Set Error Capture suppresses normal FileMaker Pro alert messages.
===================
From experience I can tell you that there is at least one error dialog that is not suppressed by SET ERROR CAPTURE ON. You may want to check the FM KB to see if it has any more details.
-Striker
RE: Error Capture doesn't suppress dialog