February 8, 200422 yr I'm trying to write a script to navigate from the main file, the user interface, decide which of 6 DB's has the actual file and goto the related record. Up until now I've known which DB to return to and written the main file script to have the related file script as the last line. That way I leave the main file and stay in the related record in the related DB. With six DB's to chose from I can't use the same method. I haven't been able to write a script to leave the main file and stay in the correct related DB. Any ideas? I use a work request# as a key field. Only one main record and one related DB record share this key. Unfortunately the related record could be in any one of the six DB. Any help would be appreciated.
February 8, 200422 yr Hi gman, I suppose you could use a construction like: (main file script) If not (IsEmpty(RelationToFile1::request#)) Goto Related Record (RelationToFile1) Perform Script (External Script in File1) else If not (IsEmpty(RelationToFile2::request#)) Goto Related Record (RelationToFile2) Perform Script (External Script in File2) : etc : Endif With the External Scripts in the 6 related databases ending with a 'halt script' or exit script' scriptstep. Hope this helps, Regards, Ernst.
February 8, 200422 yr another approach but the same idea would be.. Main File: set error capture on Open (File 1) find work request if Status(current error) = 401 open (file 2) find work request if status(current error) = 401 open (file 3) end if (from file 2) do what you want end if (from file 1) do what you want Sorry if this is confusing, but what it should do is do a find in each file. if it does not find the record, it will do a find in the next file, and so on. When it finds it it will take you to that record in that file. The other soultion is probably better. I tend to do things the hardest way possible.
Create an account or sign in to comment