CimPointList (object)

Contains the properties of a Point Collection Object.
Description: CimPointList is an enumeration of CimPoint objects. The CimPointList is returned from the CimProject.Points property. Existing points can be retrieved and modified and new points can be added to the CimPointList object.

Examples

' Attach to project and go into dynamic mode
Dim project As CimProject
Set project = CreateObject("CimProject")
project.OpenLocalProject "c:\myproject\myproject.gef"
project.ProjectUserName = "ADMINISTRATOR"
project.ProjectPassword = ""
project.dynamicMode = True

Dim Points As CimPointList
Set Points = project.Points

' Create a new global point with an initial value to '0'
Dim point as CimPoint
Set point = points.NewPoint("G1", "INT")

point.ResourceID = "$SYSTEM"
point.Type = cimGlobal
point.DerivedPoint.InitState = cimInitialized
point.DerivedPoint.InitValue = "0"
point.PointAlarm.AlarmConfigured = False
Points.Save point, True

' Create a new device point
Dim point as CimPoint
Set point = points.NewPoint("R1", "INT")

point.ResourceID = "$SYSTEM"
point.Type = cimDevice
point.DevicePoint.DeviceId = "C_9030"
point.DevicePoint.Address = "%R1000"
point.PointAlarm.AlarmConfigured = False
Points.Save point, True

' Create a new device point
Dim point as CimPoint
Set point = points.AddDevicePoint("R1", "UINT", "C_9030", "%R1"_
                                         , 1, False)
' Loop through all points and change the resource non-dynamically
For Each point in points
   ' System points cannot be modified
   If left$(point.PointId,1) <> "$" Then
      point.ResourceId ="MACHINE_1"
      points.Save point, False
   End If
Next point
Properties: Count , Item
Methods: AddDevicePoint , Delete , NewPoint , Save