If I understand you correctly, I would not use LotusScript at all. Let's say you have a document containing a numeric field called "Dollars." You want the field to appear blank (not zero) when the user edits the Lotus Notes document. You could just add an input translation formula to the dollars field like this:
Of course, this will change the value of the field if the document is saved. However, in Lotus Notes, you should be designing all views, agents, etc., to expect numeric fields to sometimes have a null string value, since that's what Formula language returns when you access an uninitialized field.
But, if that's not possible, you could create a "shadow" editable field and make "dollars" hidden so that "dollars" actually gets updated only if the shadow field is changed.
To detect when a field changes, use another hidden "check" field. Place a hidden, "computed for display" check field at the bottom of the form with its value set to its own name. Then add code (either Formula language or script) to the form's post-recalc event that detects when this check field and your editable shadow field have different values, and sets the dollars field and the check field appropriately.
Do you have comments on this Ask the Expert Q&A? Let us know.
This was first published in May 2006