setAdd

Adds a value to a set. Returns true if the value was added, or false if it was already in the set.

setAdd(set, value) → returns boolean

Member Function Syntax

mySet.add(value)

This function requires Adobe ColdFusion 2025.0.8 and up.  Not supported on Lucee, etc.

Argument Reference

set any
Required

The set.

value any
Required

The value to add.

Links more information about setAdd

Examples
Sample code invoking the setAdd function

Signup for cfbreak to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.

Fork me on GitHub