Skip to main content

Delete-Element

Command Description

Delete elements from a set

Command Prototype

Set.Remove(ObjSet,varValue)

Parameter Description

ParameterRequiredTypeDefaultDescription
ObjSetTrueexpressionObjSetThe set object to operate on
varValueTrueexpressionvarValueThe element to be removed from a set. Can be any type of data

Demo

Dim ObjSet 
ObjSet = Set.Create()
Set.Add(ObjSet,1)
Set.Add(ObjSet,2)
Set.Add(ObjSet,3)
// ObjSet = {1,2,3}

Set.Remove(ObjSet,2)
TracePrint(ObjSet)
/**
ObjSet = {1,3}
*/