PhasedSubmissionPromote

Promotes a submission phase to a specified review level, given the member IDs of a cell in the phase.

To promote by passing a phase ID, use PhasedSubmissionPromote2.

Syntax

<HsvProcessFlow>.PhasedSubmissionPromote lScenario, lYear, lPeriod, lEntity, lParent, lValue, lAccount, lICP, lCustom1, lCustom2, lCustom3, lCustom4, vbUseAllValueMembers, bstrAnnotation, sProcessStateToPromoteTo, psNewProcessState
ArgumentDescription
lScenarioLong (ByVal). The member ID of the process unit's Scenario dimension member.
lYearLong (ByVal). The member ID of the process unit's Year dimension member.
lPeriodLong (ByVal). The member ID of the process unit's Period dimension member.
lEntityLong (ByVal). The member ID of the process unit's child Entity dimension member.
lParentLong (ByVal). The member ID of the process unit's parent Entity dimension member.
lValueLong (ByVal). The member ID of the process unit's Value dimension member.
lAccountLong (ByVal). The member ID of the cell’s Account dimension member.
lICPLong (ByVal). The member ID of the cell’s Intercompany Partner dimension member.
lCustom1Long (ByVal). The member ID of the cell’s Custom1 dimension member.
lCustom2Long (ByVal). The member ID of the cell’s Custom2 dimension member.
lCustom3Long (ByVal). The member ID of the cell’s Custom3 dimension member.
lCustom4Long (ByVal). The member ID of the cell’s Custom4 dimension member.
vbUseAllValueMembersBoolean (ByVal). Specifies whether to apply the action to submission phases for Value dimension members related to the lValue member. Pass TRUE to apply the action to related submission phases.
bstrAnnotationString (ByVal). The comment for the process management action.
sProcessStateToPromoteToInteger (ByVal). The constant that identifies the level to which to promote the submission phase. Use one of the CEnumProcessFlowStates enumeration constants listed in Table 136, CEnumProcessFlowStates Enumeration.
psNewProcessStateInteger. Returns the CEnumProcessFlowStates enumeration constant that represents the review level resulting from the action.

Example

The following function promotes a given cell's submission phase to a given review level. The function uses GetPhasedSubmissionState to test whether the submission phase's current review level is less than the specified review level, and returns an array that indicates the submission phase's review level and whether it was promoted.

Function PromotePhase(lScen As Long, lYear As Long, lPer As Long, lEnt As _
    Long, lPar As Long, lVal As Long, lAcct As Long, lIcp As Long, _
    lC1 As Long, lC2 As Long, lC3 As Long, lC4 As Long, iNewState As _
    Integer, sNote As String) As Variant
Dim cProcessFlow As HsvProcessFlow, iState As Integer
Dim iRetState As Integer, vaRet(1) As Variant
vaRet(0) = False
'g_cSession represents an HsvSession instance
Set cProcessFlow = g_cSession.ProcessFlow
cProcessFlow.GetPhasedSubmissionState lScen, lYear, lPer, lEnt, _
    lPar, lVal, lAcct, lIcp, lC1, lC2, lC3, lC4, iState
If iState < iNewState Then
    cProcessFlow.PhasedSubmissionPromote lScen, lYear, lPer, lEnt, _
    lPar, lVal, lAcct, lIcp, lC1, lC2, lC3, lC4, False, sNote, _
    iNewState, iRetState
    vaRet(1) = iRetState
    vaRet(0) = True
Else
    vaRet(1) = iState
End If
PromotePhase = vaRet
End Function