MESCIUS.ActiveReports.Core.Data.VBFunctionLib Assembly / GrapeCity.Enterprise.Data.VisualBasicReplacement Namespace / Interaction Class / Switch Method
Required. Object parameter array. Must have an even number of elements. You can supply a list of Object variables or expressions separated by commas, or a single-dimensional array of Object elements.

Switch Method (Interaction)
Evaluates a list of expressions and returns an Object value corresponding to the first expression in the list that is True.
Syntax
'Declaration
 
Public Shared Function Switch( _
   ByVal ParamArray VarExpr() As Object _
) As Object
 

Parameters

VarExpr
Required. Object parameter array. Must have an even number of elements. You can supply a list of Object variables or expressions separated by commas, or a single-dimensional array of Object elements.

Return Value

Evaluates a list of expressions and returns an Object value corresponding to the first expression in the list that is True.
Exceptions
ExceptionDescription
Number of arguments is odd.
See Also