VarType.EdLimitItem



EdLimitItem(vIndex As Variant) As EdLimit

Parameters

vIndex As Variant
The limit can be selected via a number (counting starts at 0) or via a string (name of the limit).
ED
avaliable
RT
not used

Remarks

This method returns an "EdLimit" object from a datatype.

Sample:


Sub EdLimitItem()

Dim zVarTypes As VarTypes   'Object from type VarTypes
Dim zVarType As VarType 'Child object from type VarTypes
Dim zEdLimit As EdLimit 'Object from type EdLimit

'Fill the objects
Set zVarTypes = MyWorkspace.ActiveDocument.VarTypes
'Read the datatype INT from the list.Project some limits at the datatype.
Set zVarType = zVarTypes.Item("INT")
'Create a Limit at the INT datatype
zVarType.CreateEdLimit
'Returns a EdLimit object from the first limit
Set zEdLimit = zVarType.EdLimitItem(0)

'Set the limit active
zEdLimit.Active = True
'Set limit text
zEdLimit.Text = "Limit reached"
'Set limit value to 10
zEdLimit.LimitValue = 10
'Set the limit as maximum
zEdLimit.IsMax = True
'Set the limit as alarm
zEdLimit.Alarm = True
'Limit should be recognized in the CEL
zEdLimit.Cel = True

End Sub


See Also

VarType, EdLimit