EnumAuditTasks2

Returns task audit information from a given range of audit records that meet the selection criteria. Criteria include task, date range, application server, and user. Audit information is returned in arrays that have a one-to-one correspondence.

Note:

To return audit information for all tasks, either set the vbAllTasks argument to FALSE or use EnumAuditTasks.

The lStartRecord and lEndRecord arguments specify the starting and ending indexes of the range of records, and the plTotalNumRecords argument returns the total number of records that match the selection criteria. To iterate through all the matching records, in the first call to EnumAuditTasks2 pass 0 to lStartRecord, then use the count returned by plTotalNumRecords to loop through the remaining records.

Note:

The number of matching records can change after you call EnumAuditTasks2. For example, a user might delete some or all of the audit records.

Syntax

<HsvSystemInfo>.EnumAuditTasks2 dStartTime, dEndTime, vbAllServers, bstrServer, vbAllUsers, lActivityUserID, vbAllTasks, lActivityTaskID, lStartRecord, lEndRecord, pvaralActivityUserID, pvarabstrActivityUserName, pvaralActivitySessionID, pvarbstrServerName, pvaralActivityCode, pvaradStartTime, pvaradEndTime, pvarbstrDescription, pvarbstrModuleNames, plTotalNumRecords

Argument

Description

dStartTime

Double (ByVal). The starting date and time of the date range. Pass a Double that can be cast to a Date format.

dEndTime

Double (ByVal). The ending date and time of the date range. Pass a Double that can be cast to a Date format.

vbAllServers

Boolean (ByVal). Specifies whether audit information for all application servers is returned. Pass TRUE for all application servers, FALSE to specify an application server with the bstrServer argument.

bstrServer

String (ByVal). The name of the application server for which to return audit information. This argument is used only if the vbAllServers argument is set to FALSE.

vbAllUsers

Boolean (ByVal). Specifies whether audit information for all users is returned. Pass TRUE for all users, FALSE to specify a user with the lActivityUserID argument.

lActivityUserID

Long (ByVal). The activity user ID of the user for whom to return audit information. This argument is used only if the vbAllUsers argument is set to FALSE.

To get a user’s activity user ID, use GetActivityUserID.

vbAllTasks

Boolean (ByVal). Specifies whether audit information for all tasks or a given task is returned. Pass TRUE for all tasks, FALSE to specify a task with the lActivityTaskID argument.

lActivityTaskID

Long (ByVal). The ID of the task for which to return audit information. This argument is used only if the vbAllTasks argument is set to FALSE.

Task IDs are represented by the HFMConstants type library constants listed in User Activity Constants.

lStartRecord

Long (ByVal). The index of the first record in the range of records to retrieve. This is a zero-based index.

lEndRecord

Long (ByVal). The index of the last record in the range of records to retrieve. This is a zero-based index.

pvaralActivityUserID

Variant array. Returns the activity user IDs for the users who performed the tasks.

The array is returned as a Long subtype.

pvarabstrActivityUserName

Variant array. Returns the usernames of the users who performed the tasks.

The array is returned as a String subtype.

pvaralActivitySessionID

Variant array. Returns the internal IDs of the sessions in which the tasks occurred.

The array is returned as a Long subtype.

pvarbstrServerName

Variant array. Returns the names of the application servers on which the tasks occurred.

The array is returned as a String subtype.

pvaralActivityCode

Variant array. Returns the IDs of the tasks performed by the users. Valid values are represented by the HFMConstants type library constants listed in User Activity Constants.

The array is returned as a Long subtype.

pvaradStartTime

Variant array. Returns the starting times of the tasks. Array items are formatted as Doubles that can be cast to the Date format.

The array is returned as a Double subtype.

pvaradEndTime

Variant array. Returns the ending times of the tasks. Array items are formatted as Doubles that can be cast to the Date format.

The array is returned as a Double subtype.

pvarbstrDescription

Variant array. Returns the descriptions of the tasks.

The array is returned as a String subtype.

pvarbstrModuleNames

Variant array. Returns the names of the modules for the tasks.

The array is returned as a String subtype.

plTotalNumRecords

Long. Returns the total number of audit records in the database that meet the filtering criteria.