CimProjectData.GetNext (function)

Syntax CimProjectData.GetNext(p1$ [,p2$ [,p3$…) as Boolean
Description This function returns the specified attributes for the next item that matches the filter criteria. If a record is found, a value of TRUE is returned, otherwise a value of FALSE is returned. The function takes a variable number (20 maximum) of string parameters. The values returned into the parameters are defined by the attributes specified for the object.
Comments Parameter Description
p1$ String. First attribute for the object.
: :
p20$ String. Twentieth attribute for the object.
Example 1 The following sample script returns all the data items for the PID1 object.
Sub Main()
   Dim browse as new CimProjectData
   Browse.Project = "MY_PROJ"
   Browse.Entity = "OBJECT_INF"
   Browse.Attributes = DATA_ITEM"
   Browse.Filters = "OBJECT_ID=PID1"
   Dim dataItem as String
Top:
   If Browse.GetNext(dataItem) = False then end
   Msgbox dataitem
   Goto top
End Sub
Example 2 The following sample script returns all points for a device:
Sub Main()
   Dim browse as new CimProjectData
   Browse.Project = "MY_PROJ"
   Browse.Entity = "POINT"
   Browse.Attributes = "POINT_ID,RESOURCE_ID"
   Browse.Filters = "DEVICE_ID=PLC1"
Top:
   If Browse.GetNext(p$,r$) = False then end
   Msgbox "Point Id " & p$ & " Resource id " & r$
   Goto top
End Sub