O'Reilly logo

Microsoft Dynamics NAV 2015 Professional Reporting by Steven Renders

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Conditional formatting in a report

Conditional formatting means using expressions to determine how information is formatted. In its simplest form, and in most common examples, it is used in the color (and background color) properties. An example is using the following expression for the color property of a textbox:

=Iif(Me.Value > 0,"Blue","Red")

In this example, I'm using the Me object, and Me refers to the current textbox. Another example is this expression:

=Iif(Rownumber(Nothing) MOD 2,"PaleGreen","White")

If you use it for the background color property of a row then it means that the even rows will become pale green and odd rows will become white.

Note

Sometimes Me.Value is not recognized in the expression builder. It will depend on if you use ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required