Conditional Expressions

Conditional Expressions

Conditional Expressions are not permitted. Conditional behavior can be forced, when necessary, in two different ways.

IIF Function

{IIF(Condtion, ValueA, ValueB}

In the above calculation, the “Condition” is tested to determine if it evaluates to true or false. If it evaluates to true, the expression will return ValueA. If it evaluates to false, the expression will return ValueB .

Number of Cabinets: {Cabinet.Count > 0 ? Cabinet.Count : “None”}

If the value of Cabinet.Count is 3, the result in the report will be:

Number of Cabinets: 3

If the value of Cabinet.Count is 0, then the result in the report will be:

Number of Cabinets: None

C# Ternary Operator

In C#, you can use the ternary operator. For example:

{Condition ? ValueA : ValueB}

If “Condition” is true, the expression will return ValueA. If false, it will return ValueB.

    • Related Articles

    • Text Expressions

      Text expressions are the simplest expressions. Here are some examples: SampleText 54321 Example All of the expressions above are strings, and there are no calculations. These expressions would be printed as they have been defined. These types of ...
    • Using Expressions in the Rich Text Editor of Report Designer

      The articles in this section of the Knowledge Base involve working with Rich Text for display in your reports. To learn more about the Rich Text editor, and how to access this section within the Report Designer, see An Introduction to the Rich Text ...
    • Conditional Formatting

      A user can change the appearance of components by setting specific conditions. Conditional Formatting is set up using the Conditions window, found in the Home tab of the ribbon. Fig. 1 – Home > Conditions Fig. 2 – Conditions Window Add Condition – ...
    • Using Functions in Expressions

      Built-in Functions There is a variety of built-in functions available in the Report Designer. These functions can be accessed directly from the data dictionary, or from within the Expression Editor. Here is an example of a built-in function: ...
    • Multi Line Expressions

      Multiple lines of text can be produced in a report by a single expression. To create a multi-line expression, insert a line feed before any new line. To do this, press the Enter key at the appropriate place in the code editor. There is no limit to ...
    • Recent Articles

    • Toolbox Release Notes | Build 25.1.0213.641

      The following release notes apply to Toolbox build 25.1.0213.641. Stay Down Nesting Additions 3 new settings have been added to Stay Down Nesting, to resolve specific issues with routes and connectors that have been reported: Fig. 1: New options in ...
    • Toolbox Release Notes: Year of 2024

      This document will catalog all releases for Microvellum Toolbox software builds that were released in the year 2024. This encompasses builds 24.1.0104.641 to 24.1.1206.641. Toolbox Release Notes | Build 24.1.1206.641 The following release notes apply ...
    • Toolbox Release Notes | Build 25.1.0129.641

      The following release notes apply to Toolbox build 25.1.0129.641. SMA Fixes A wide variety of issues with the Solid Model Analyzer have been resolved. Multiple modifications to existing interfaces or settings have been made to improve precision and ...
    • Microvellum Foundation Library Release Notes | Build 25.0124

      The following release notes apply to Microvellum Foundation Library build 25.0124. Additions Added Century Components Waste Bins, Vanity Organizers, and Base Cabinet Organizers. 11”, 14”, 17” Signature Series Bottom Mount 34qt & 50qt. 4”, 5”, 6”, 9”, ...
    • SQL Server Backups

      This article will list out the various types of backups you can create for databases hosted on an SQL Server, explore methods for creating backups manually and automatically, as well as list software/services that may assist you with backing up your ...