Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Description

This is the Child Cardinality No Number of the relationship: 0 = Zero or One to Zero or More, 1 = 0, Zero or One to One or More, 2 = 1, Zero or One to Zero or One , 3 = 2, Zero or One to exactly N = 3. DATATYPE: Integer.

Property

...

Type

  • Read-write property

Syntax

...

Code Block
languagevb
Public Property CardinalityNo() As Variant

Remarks

Values may be:

Mandatory:

One to Zero or More = 0

...

One to One or More = 1

...

One to Zero or One = 2

...

One to Exactly N = 3

...

Optional:

...

Zero or One to Zero or More = 0

...

Zero or One to One or More = 1

...

Zero or One to Zero or One = 2

...

...

One to Exactly N = 3

Example

Sub Main
Anchorwp1024182wp1024182 
Anchorwp1024183wp1024183


Dim d As Diagram

Anchorwp1024184wp1024184Dim m As Model
anchor

wp1024185wp1024185Dim rel As Relationship
Anchorwp1024186wp1024186 
Anchorwp1024187wp1024187


Set d = DiagramManager.ActiveDiagram

Anchorwp1024188wp1024188Set m = d.ActiveModel
Anchorwp1024189wp1024189 
Anchorwp1024190wp1024190


'Force every Relationship to be Mandatory and One-To-One or More
Anchorwp1024191wp1024191 
Anchor


wp1024192wp1024192For Each rel In m.Relationships
Anchorwp1024193wp1024193

rel. = 1
Anchorwp1024194wp1024194

rel.CardinalityNo = 1
anchor

wp1024195wp1024195Next rel


anchorEnd Subwp1024196wp1024196 
Anchorwp1024197wp1024197End Sub


Info
titleSee Also