Greetings, The first thing you need to do is to figure out how to generate the error by hand - what is it that the script does to cause it. Once armed with this information, then open up your script. Set a Toggle Single Step point at the beginning of your data entry step. You can stop your script at this point if you or press the Break button.
Then tab over into Meditech and do whatever you need to cause the error. The BWS will now be "seeing" the error. Be sure you select any rule that is in your data entering step - doesn't matter exactly where, but for ease of reading the script later on, you'd likely want to select the Rule that sends the text that may cause the error. Now build the Rule by using a keying command to clear the error (Enter etc). The rule to detect the error is now directly below the selected rule. Now you may need to add a new Step to further back up the screen - all depends on what happens after you clear the error (am I at a unique prompt like Exit?, am I back in the field I started from, etc). If you need to do this, then your error detecting rule will need to Goto this "back me up" step. Fill in the Back me up step with rules to back up the screen. Then goto your get next record step etc. An interesting tidbit here, if your script encounters several of these "random errors", perform the same process as above, but reuse the "Back me up" Step since typically when backing up Meditech you encounter similar prompts. You can have as many "potential back me up points" in this Step - that's the beauty of the Rules approach - you probably can reuse this back me up in different scripts as well. And for even more fun and to handle "random errors" you haven't seen yet. You can add a Rule with a Timeout condition to the Step. This will detect if the script has been in the Step for too long - the timeout Rule goes to your "back me up" step. For style points J, add an action to the Rule that clears the error that sets the Status field in the DataStation =Error and configure a DataStation report to print out a spreadsheet of what caused the problem in the first place. Heck you could even add a Special field to the report and read the error message into it. If any of the above is unclear - please give our support line a call, they can walk you through this - no need to be plagued by random errors I assure you! Regards, Thom Thom C. Blackwell Product Manager Boston Software Systems (866) 653-5105 ex 807 www.bossoft.com LEGAL NOTICE Unless expressly stated otherwise, this message is confidential and may be privileged. It is intended for the addressee(s) only. Access to this E-mail by anyone else is unauthorized. If you are not an addressee, any disclosure or copying of the contents of this E-mail or any action taken (or not taken) in reliance on it is unauthorized and may be unlawful. If you are not an addressee, please inform the sender immediately, then delete this message and empty from your trash. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Gary Williams Sent: Friday, January 26, 2007 2:45 PM To: [email protected] Subject: [Talk] Random Errors I am in the process of writing a rules based script and have hit an error that I am stumped on. Our Transcriptionists have decided to add their own codes to meditech for a few procedures. The problem is that meditech does not like the codes and kicks up a yellow error box at the botton of the meditech workstation screen (ver 3.26). This only happens in maybe one in every 50 records or so. What's the best way to have the script see the error, back out and then continue with the next record. I have had boston training but very little vb yet. Thanks for any ideas, Gary Data Tech Memorial Hospital Belleville, IL
