ObjectList
You can use this function for Optiva workflows.
Purpose
The ObjectlList property retrieves the list of object IDs being performed in the current batch of Workflows-In-Progress (WIP).
Syntax
Dim variable() As String = Context.ObjectList
Description
Optiva creates a Workflow-In-Progress (WIP) for each object selected in the workspace.
The ObjectlList property is used to:
- Determine if the workflow is a part of batch of the objects.
- Return an array of object ID codes for the current workspace.
You can run a single WIP for all the objects by creating the workflow script code using the object ID codes.
The remaining WIPs exit the script with a return code 111.
Example
Below is the example for the object ID created using the ObjectlList property.
Option Strict On
Imports System
Class ActionScript
Inherits FcProcFuncSetEventWF
Function wf_start() As Long
Message List("Object list: ")
For i As Integer = 0 To Context.ObjectList.Length - 1
Dim objectCodeEntry As String = Context.ObjectList(i)
Dim isCurrentObject As Boolean = (objectCodeEntry = _OBJECTKEY)
If isCurrentObject Then
MessageList(String.Format("{0} - {1} <-- CURRENT ObjectKey", i, objectCodeEntry))
Else
MessageList(String.Format("{0} - {1}", i, objectCodeEntry))
End If
Next i
Return 111
End Function
End Class