BoolList.SetItemValue(String, Boolean) Method

Assigns a new value to a particular key from the BoolList's collection of key/value pairs.

Namespace: DevExpress.ExpressApp.Utils

Assembly: DevExpress.ExpressApp.v18.1.dll

Syntax

public void SetItemValue(
    string key,
    bool value
)

Parameters

Type Name Description
String key

A string representing the key from the BoolList's collection of key/value pairs, to which a new value will be assigned.

Boolean value

A Boolean value to be assigned to the specified key.

If a key/value pair with the specified key does not exist, it is created.

The following code snippet illustrates use of the SetItemValue method:

BoolList mylist = new BoolList();
mylist.SetItemValue("myKey", true); 
//myValue == true;

To get all keys from the BoolList's collection of key/value pairs, use the BoolList.GetKeys method. To check whether a particular key exists, use the BoolList.Contains method.