AquaLogic Interaction Development Kit (IDK) 6.0.0 |

# ISelectionListManager.CreateSelectionList Method

Creates a new `ISelectionList` instance.

ISelectionList CreateSelectionList(
IFolder containingFolder,
string name,
string[] values
);

#### Parameters

containingFolder
  The folder the new selection list will be created in; cannot be `null`.
name
  The name of the selection list; cannot be `null`, empty, or longer than 255 characters. The string used for the name will be trimmed of leading and trailing whitespace when it is stored and is case-insensitive during name comparison. If there is another selection list with the same name in the folder a `NameAlreadyInUseException` will be thrown when `ISelectionList.Store` is called.
values
  The initial text values of the selection list; cannot be `null`, an empty string, or a string longer than 255 characters. Text values will preserve whitespace when stored and are case-sensitive during comparison. Duplicate text values will only be added once. The order of the values will be preserved.

#### Return Value

A new `ISelectionList` instance.

#### Remarks

`ISelectionList.Store` must be called to persist the newly-created selection list.

An `InvalidOperationException` will be thrown if the containing folder has not been stored.

#### Exceptions

Exception Type | Condition
--- | ---
InvalidOperationException | The specified folder has been deleted or has not been stored.
ArgumentException | The `name` is an empty string or longer than 255 characters, or there is an empty string or string longer than 255 characters in the `values` array.

#### See Also

ISelectionListManager Interface | Plumtree.Remote.PRC.Content.SelectionList Namespace