API
@-Formulas
JavaScript
LotusScript
Reg Exp
Web Design
Notes Client
XPages
 
Error Message In Status Bar
Every once in a while, when opening a document with the Notes client, you may notice an error message in the status bar. Since nothing "pops-up" in front of you, the error message may not be noticed. An example of this is shown in figure 1:

What causes this error and what do you do about it?

Well, if the error is in some LotusScript, then you should get a pop up of "Object Variable Not Set" or whatever the error happens to be. If the error is with a computed or computed for display field, that error should pop up also. If you are composing a document and the error is in a default field value for an editable computed or with a computed when composed field, that error also will pop up in front of you. So what does that leave?

The only thing left is hide-when formulas. So the fact that the error is in the status bar instead of displaying a pop-up means that the error is with a hide-when formula. Now, how to track it down? Unfortunately there isn't a good explanation here, but I can give you some steps.

The first thing to do is make a copy of your form. You're going to be messing with the existing form quite a bit, so you'll need a way to get back to the original design.

The first thing to check is your action buttons. Those are often forgotten for hide-when formulas. Look to see if there are any formulas applied to show/hide the action button(s). Remove the formula from one button and test the form again. If the error goes away, you know what button is causing the error. If the error is still there, LEAVE THE FORMULA OFF and remove the formula from another button. If you replace the formula, it is quite possible that multiple formulas are causing the error and you would never find out which ones are bad if only one is removed at a time.

Once you have made it all the way through action buttons and the error still appears, check action buttons in any and all subforms. Those are often forgotten as well. Again, the formulas that have already been removed should stay removed until you track down the culprit. That's why the copy of the form was made.

If you make it all the way through all the action buttons and the error still appears, then the error is on your form. Break your form up into "pieces" (4 or 5 depending on the size of your form, but probably not more than that). Highlight everything in a block and go to the hide when tab under text properties. If some parts of the highlighted block had a hide formula and others didn't, the check mark for the hide formula will be gray instead of black. What you want to do is put a value in the hide when formula of 0 (the number zero) and click on the check mark a time or two until it is a solid black check. Then get out of your form and get back in (save the changes). Highlight the same block of text and go to the hide when tab again. The formula of 0 should be in there and the check mark should be a solid black. Remove the formula and check the box again to remove the checkmark. Save and close the form and try it out again. If the error message still appears, repeat the above process with the next block.

At some point, the error will go away. When that happens, you know what block or action button caused the error. Replace your form from the copy you made at the start and track it down further. If it was an action button, see what the hide formula of the action button is doing. If the error was in a block of text and the block is large, you can repeat the above process with "sub-blocks" of text.

If you can't tell if there is anything wrong with your formula, remove the formula and test it out, just to make sure that's what it is (and to make sure there's not two formulas in error on the form). There may be dependencies with fields that haven't been set yet (at the time the formula is being computed). There may be assumptions made about the data type of a value (a number is being used when you think it's text or the other way around). Unfortunately, there's no "magic wand" to wave - you have to track it down. But at least this should give you some ideas to work with.