Returns information about the running tasks that meet the selection criteria. Criteria include task type, user, application server, user session, and task status. Task information is returned in arrays that have a one-to-one correspondence.
To also return flags that indicate whether the tasks currently are running or stopped, use EnumRunningTasksEx. |
The lStartRecord and lEndRecord arguments specify the starting and ending indexes of the range of records, and the plTotalRecords argument returns the total number of records that match the selection criteria. To iterate through all the matching records, in the first call to EnumRunningTasks pass 0 to lStartRecord, then use the count returned by plTotalRecords to loop through the remaining records.
The number of matching records can change after you call EnumRunningTasks. For example, a new task could be added. |
<HFMwSystemInfo>.EnumRunningTasks (vbAllTaskTypes, lTaskType, vbAllUsers, bstrUserName, vbAllServers, bstrServerName, vbAllSessions, vbAllStatus, lStatus, lStartRecord, lEndRecord, pvaravarTaskIDs, pvaravarTaskTypes, pvaravarTaskProgress, pvaravarTaskStatus, pvaravarUserNames, pvaravarServerNames, pvaravarStartTimes, pvaravarStartRunningTimes, pvaravarLastUpdateTimes, pvaravarDescriptions, pvaravarLogFiles)
A flag that specifies whether to filter for a specific type of task. Pass TRUE to return information for all tasks, FALSE to filter by the type of task specified by the lTaskType argument. | |
Long (ByVal). The ID of the task type for which to return information. This argument is used only if the vbAllTaskTypes argument is set to FALSE. Following are the constants that represent valid values. These are from the HFMConstants enumeration tagUSERACTIVITYCODE:
| |
A flag that specifies whether to filter by user. Pass TRUE for all users, FALSE to filter by the user specified with the bstrUserName argument. | |
The username for which to return task information. This argument is used only if the vbAllUsers argument is set to FALSE. | |
A flag that specifies whether to filter by application server. Pass TRUE for all application servers, FALSE to filter by the application server specified with the bstrServerName argument. | |
The name of the application server for which to return task information. This argument is used only if the vbAllServers argument is set to FALSE. | |
Specifies whether to return information for all user sessions or only the session for the connected user. Pass TRUE for all sessions, FALSE otherwise. | |
Specifies whether to filter by task status. Pass TRUE for all statuses, FALSE to filter by the status specified with the lStatus argument. | |
The task status by which to filter. This argument is used only if the vbAllStatus argument is set to FALSE. Valid values are represented by the HFMConstants type library constants listed in Task Status Constants. | |
The index of the first record in the range of records to retrieve. This is a zero-based index. | |
The index of the last record in the range of records to retrieve. This is a zero-based index. | |
Returns an array containing the task IDs that identify the running tasks. | |
Returns an array containing the tasks’ types. Valid values are represented by the constants listed as valid values for the lTaskType argument. | |
Returns an array containing the progress complete percentages of the running tasks. | |
Returns an array containing the tasks’ statuses. Valid values are represented by the HFMConstants type library constants listed in Task Status Constants. | |
Returns an array containing the usernames of the running tasks’ users. | |
Returns an array containing the names of the application servers for the running tasks. | |
Returns an array containing the timestamps of the tasks’ scheduled start times. Array items are formatted as Doubles that can be cast to the Date format. | |
Returns an array containing the timestamps of the tasks’ actual start times. Array items are formatted as Doubles that can be cast to the Date format. | |
Returns an array containing the timestamps of the last time the tasks were updated. Array items are formatted as Doubles that can be cast to the Date format. | |
Returns an array containing the descriptions for the tasks. The array is returned as a String subtype. | |
Returns an array containing the file names and paths of the tasks’ log files. |
Returns a count of the number of tasks returned by EnumRunningTasks.