VarTypes

 

Remarks Properties Methods Samples

ED
avaliable
RT
not used

Remarks:Top

With the object VarTypes you have the opportunity to create, delete and edit datatypes from the list of datatypes.

Properties:Top

Count Parent  

Methods:Top

CanDeleteType CreateComplexType CreateSimpleType
DeleteType Export Import
Item    

Samples:Top



Sub CreateComplexType()

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

'Fill the objects
Set zVarTypes = MyWorkspace.ActiveDocument.VarTypes

'Create a structure datatype called "Structure_1"
Set zVarType = zVarTypes.CreateComplexType("Structure_1")
Call CreateSimpleType

End Sub

Sub CreateSimpleType()

Dim zVarTypes As VarTypes   'Object from type VarTypes
Dim zVarType As VarType 'Child object from type VarTypes
Dim zVarTypes_1 As VarTypes
Dim zVarType_1 As VarType

'Fill the objects
Set zVarTypes = MyWorkspace.ActiveDocument.VarTypes
Set zVarTypes_1 = MyWorkspace.ActiveDocument.VarTypes

'Read datatype "UINT"
Set zVarType_1 = zVarTypes_1.Item(1)

'Create a simple datatype from type "UINT" called "SimpleType_1"
Set zVarType = zVarTypes.CreateSimpleType("SimpleType_1", zVarType_1)

End Sub