Assigning Object Appearance and Behavior Using Properties

From ER/Studio Data Architect
Jump to: navigation, search

Go Up to Automation Objects Programmer's Guide

Properties are Object attributes that determine Object appearance or behavior. Color, count, name and ID all are properties common to many objects. Some, such as ID, are usually read-only. Others can be changed. ER/Studio Data Architect immediately reflects property modifications by updating internal data.

Dim MyDiagram As Diagram

Dim MyModel As Model

Dim MyEntity As Entity

Dim EntName As String

Dim EntID As Integer

Set MyDiagram = DiagramManager.ActiveDiagram

Set MyModel = MyDiagram.ActiveModel

EntID = 1 'We want the name of the Entity that ER/Studio Data Architect has identified as ID =1

Set MyEntity = MyModel.Entities.Item(EntID)

EntName = MyEntity.EntityName

'Now we can display EntName in a MsgBox, write it to a text file, or
'change it and re-name the Entity.

See Also