Manage Learn to apply best practices and optimize your operations.

Minimizing hide/when

Using the following method, I have less trouble with hide/when "crapping out" - especially with @IsNewDoc and !@IsNewDoc.

Working with Web applications - I do not know if this is as big an issue with the Notes client itself...

If you have a lot of Hide/When formulae on a form - you always run the risk that for no good reason they will suddenly all fail and whatever you do you have to rebuild everything from scratch which can be VERY irritating.

I have found that by using the following method I have less trouble with it "crapping out" - especially with @IsNewDoc and !@IsNewDoc.

"Computing for Display" a single field value to @True or @False allows the Hide/When formulae of a paragraph to contain just a single field name. This means that the Hide/When formulae do not perform any @Formulae computations. In my experience this has made my forms more stable and I have had less trouble with the Hide/Whens failing on me.

There is also a speed advantage when you are using the same formulae on many paragraphs - you are only computing @IsNewDoc once rather than many times.

1) Example of code for a Computed for Display field called "hwNewDoc"

@If(@IsNewDoc; @True; @False)

2) Hide/When formula for Field hidden when @IsNewDoc

"Hide Paragraph if formula is true"


3) Hide/When formula for Field hidden when !@IsNewDoc becomes

"Hide Paragraph if formula is true"


All you need to add in the Hide/When formulae is the name of the field. If the field is set to @true then it will be hidden

For adding usability and simplifying complicated hide/when formulae this method can be applied using more computed for display fields

using two fields for hwNewDoc and a field for a UserRole...

4) Example of code for a field called "hwIsAdmin"

@If(@IsMember("[Admin]"; @UserRoles); @True; @False)

5) Hide/When formula for Field hidden when !@IsNewDoc | @IsNotMember
("[Admin]"; @UserRoles) becomes

"Hide Paragraph if formula is true"

hwNewDoc | !hwIsAdmin

Dig Deeper on Domino Resources - Part 4

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.




  • iSeries tutorials's tutorials provide in-depth information on the iSeries. Our iSeries tutorials address areas you need to know about...

  • V6R1 upgrade planning checklist

    When upgrading to V6R1, make sure your software will be supported, your programs will function and the correct PTFs have been ...

  • Connecting multiple iSeries systems through DDM

    Working with databases over multiple iSeries systems can be simple when remotely connecting logical partitions with distributed ...