kiwiora Posted May 23, 2003 Posted May 23, 2003 Hi guys, The scenario: I have a database of people's cv's. CV's are updated continuously, so what I have done is made a field of the "filename" with the path + name of person and created a script to open the file. e.g """" & "P:BCV - Brisbane CVs" & Author & ".doc" & """" This works beautifully. Problem: On my script i have the error capture turned on, but what i would really like is a conditional statement that would open the file, or if null, send a message saying it doesn't exist. I know I can do conditional statements when a field is "", but how do i do it when the thing i am looking for is external to filemaker?? i.e there will always be an entry in the filename field so it will never be null, but there may not be a document to open with that filename. Hope that makes sense...
bradm98 Posted May 23, 2003 Posted May 23, 2003 Take a look at the Status(CurrentError) function in FileMaker help. I believe it lists error codes. I'm not sure which one corresponds to "file not found," but you can trap for that error code and handle it in your script...
Fitch Posted May 27, 2003 Posted May 27, 2003 I have found that I almost never need to trap for a specific error, so unless there's a specific need, I just use: Status(CurrentError) <> 0 ...that pretty well covers all your bases.
Recommended Posts
This topic is 7854 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now