Create Dynamic Plurals by Using the IIf function

Category:
String Manipulation
Type:
Snippets
Difficulty:
Beginning
Author:
Ethan

Version Compatibility:

More information:
To create dynamic plural data use the IIF Function. The attached code contains examples with multi-dimensional arrays and recordsets. The idea is that if a particular value that represents a quantity is 1, don't add s to the name of the value. Otherwise, add s.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: