Returns arrays containing the history of a process unit; the process unit’s dates and times, users, actions, levels, comments, and names and paths of attached document are returned. The arrays have a one-to-one correspondence.
<HsvProcessFlow>.GetHistory2 lScenario, lYear, lPeriod, lEntity, lParent, lValue, pvaradTime, pvarabstrUser, pvarasAction, pvarasNewState, pvarabstrAnnotation, pvaravarabstrPaths, pvaravarabstrFiles
Long (ByVal). The member ID of the process unit's Scenario dimension member. | |
Long (ByVal). The member ID of the process unit's Year dimension member. | |
Long (ByVal). The member ID of the process unit's Period dimension member. | |
Long (ByVal). The member ID of the process unit's child Entity dimension member. | |
Long (ByVal). The member ID of the process unit's parent Entity dimension member. | |
Long (ByVal). The member ID of the process unit's Value dimension member. | |
Variant. Returns an array of the process unit’s times and dates. The array is returned as a Double subtype. The numbers returned in this array are in a standard date format; for example, in Visual Basic you can convert a returned array element by passing it to CDate. | |
Variant. Returns an array of the usernames that have performed actions for the process unit. The full usernames — the domains and the usernames — are returned. | |
Variant. Returns an array of the process unit’s actions. The valid return values are listed in Process Management Action Constants. | |
Variant. Returns an array of the process unit’s levels. The valid return values are listed in Table 136, CEnumProcessFlowStates Enumeration. | |
Variant. Returns an array of the process unit’s comments. The array is returned as a String subtype. | |
Variant. Returns an array of arrays that contain the paths of attached documents for each action. The array is returned as a String subtype. | |
Variant. Returns an array of arrays that contain the names of attached documents for each action. The array is returned as a String subtype. |
The following example prints the times of a process unit’s approvals, as well as the names and paths of documents attached to approvals. The example assumes that the process unit’s dimension member IDs have been specified.
Dim cProcessFlow As HsvProcessFlow, vaTimes, vaUsers Dim vaActions, vaStates, vaNotes, vaPaths, vaNames 'g_cSession is an HsvSession object reference Set cProcessFlow = g_cSession.ProcessFlow 'the example assumes that member IDs have been specified cProcessFlow.GetHistory2 lScen, lYear, lPer, lEnt, lPar, lVal, vaTimes, _ vaUsers, vaActions, vaStates, vaNotes, vaPaths, vaNames For i = LBound(vaActions) To UBound(vaActions) If vaActions(i) = PROCESS_FLOW_ACTION_APPROVE Then Debug.Print CDate(vaTimes(i)) If IsArray(vaPaths(i)) Then For j = LBound(vaPaths(i), 1) To UBound(vaPaths(i), 1) Debug.Print vaPaths(i)(j) & "\" & vaNames(i)(j) Next j End If End If Next i