« Whoooohoooo! I'm recertified! | Main| Worst Practices... (continued) »

Worst Practices....

Tags: development

Currently I have to migrate documents from a (very complex) Notes/Domino application (written by someone else, no, not at our company!) to a Notes/Domino application written by us. By the way: the same bl**dy application as
blogged some time ago.

After migrating some documents I tested them. I noticed, that my input validation (done by QuerySave, calling some script library functions as we have to do some complex computation) was broken: I was able to enter wrong data, got a (correct) error message - but when I cancelled out the trash had been saved.


So I started debugging the input validation, the script library, and so on. But I could not explain what was going on - I searched for a NotesDocument.save in the LS code, then for @Command([FileSave]) in some of the buttions. But of course I could not find anything (who would do such things?).


Finally I found out.


They had saved *some* (not all) of their documents with an item "SaveOptions", which was set to 1. And of course that was neither visible in the forms nor commented anywhere. Which leads to saving the documents when cancelling without even being asked.

Comments

Gravatar Image1 - SaveOptions - can be very helpfull but it can burn, been there. Maybe there could be a debug mode for developers when using a form that would allow us to see fields like SaveOptions and other system fields. Better yet the option to see the hidden fields on the form, better than having to bring up the properties box to see the data.

Post A Comment

:-D:-o:-p:-x:-(:-):-\:angry::cool::cry::emb::grin::huh::laugh::lips::rolleyes:;-)

Search

Calendar

MiscLinks

We Use Ytria Lotus Notes Tools For Faster Notes Development and Better Domino Administration

Tags

Site Info