Public Function Add() As Condition
Public Sub AddingConditions() Dim oConditions As SAPbouiCOM.Conditions Dim oCondition As SAPbouiCOM.Condition '// create a new conditions collection Set oConditions = New SAPbouiCOM.Conditions '// the requested conditions '// WHERE ((CardType = 'C') Or (CardType = 'S')) '// the conditions collection encapsulates the WHERE clause '// of a select statement Set oCondition = oConditions.Add '// ((CardType = 'C') Or oCondition.BracketOpenNum = 2 oCondition.Alias = "CardType" oCondition.Operation = co_EQUAL oCondition.CondVal = "C" oCondition.BracketCloseNum = 1 oCondition.Relationship = cr_OR Set oCondition = oConditions.Add '// (CardType = 'S')) oCondition.BracketOpenNum = 1 oCondition.Alias = "CardType" oCondition.Operation = co_EQUAL oCondition.CondVal = "S" oCondition.BracketCloseNum = 2 End Sub
Conditions Collection